Computing probability density function of the well-known mixture models
Description
Computes probability density function (pdf) of the mixture model. The general form for the pdf of the mixture model is given by
f(x,Θ)=∑j=1Kωjfj(x,θj),
where Θ=(θ1,…,θK)T, is the whole parameter vector, θj for j=1,…,K is the parameter space of the j-th component, i.e. θj=(αj,βj)T, fj(.,θj) is the pdf of the j-th component, and known constant K is the number of components. The vector of mixing parameters is given by ω=(ω1,…,ωK)T where ωjs sum to one, i.e., ∑j=1Kωj=1. Parameters αj and βj are the shape and scale parameters of the j-th component or both are the shape parameters. In the latter case, the parameters α and β are called the first and second shape parameters, respectively. We note that the constants ωjs sum to one, i.e. ∑j=1Kωj=1. 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 with pdf given by the following.
where θ=(α,β). In the skew-normal case, ϕ(.) and Φ(.) are the density and distribution functions of the standard normal distribution, respectively.
Usage
dmixture(data, g, K, param)
Arguments
data
Vector of observations.
g
Name of the family including "birnbaum-saunders", "burrxii", "chen", "f", "Frechet", "gamma", "gompetrz", "log-normal", "log-logistic", "lomax", "skew-normal", and "weibull".
K
Number of components.
param
Vector of the ω, α, β, and λ.
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 pdf of the mixture model of families computed at data.