pmixture {ForestFit} | R Documentation |
Computing cumulative distribution function of the well-known mixture models
Description
Computes cumulative distribution function (cdf) of the mixture model. The general form for the cdf of the mixture model is given by
where , is the whole parameter vector,
for
is the parameter space of the
-th component, i.e.
,
is the cdf of the
-th component, and known constant
is the number of components. The vector of mixing parameters is given by
where
s sum to one, i.e.,
. Parameters
and
are the shape and scale parameters or both are the shape parameters. In the latter case, the parameters
and
are called the first and second shape parameters, respectively. The families considered for each component include Birnbaum-Saunders, Burr type XII, Chen, F, Frechet, Gamma, Gompertz, Log-normal, Log-logistic, Lomax, skew-normal, and Weibull.
Usage
pmixture(data, g, K, param)
Arguments
data |
Vector of observations. |
g |
Name of the family including: " |
K |
Number of components. |
param |
Vector of the |
Details
For the skew-normal case, ,
, and
are the location, scale, and skewness parameters, respectively.
Value
A vector of the same length as data
, giving the cdf of the mixture model computed at data
.
Author(s)
Mahdi Teimouri
Examples
data<-seq(0,20,0.1)
K<-2
weight<-c(0.6,0.4)
alpha<-c(1,2)
beta<-c(2,1)
param<-c(weight,alpha,beta)
pmixture(data, "weibull", K, param)