Learn R Programming

mclust (version 3.4.7)

defaultPrior: Default conjugate prior for Gaussian mixtures.

Description

Default conjugate prior specification for Gaussian mixtures.

Usage

defaultPrior(data, G, modelName, ...)

Arguments

data
A numeric vector, matrix, or data frame of observations. Categorical variables are not allowed. If a matrix or data frame, rows correspond to observations and columns correspond to variables.
G
The number of mixture components.
modelName
A character string indicating the model: "E": equal variance (univariate) "V": variable variance (univariate) "EII": spherical, equal volume "VII": spherical, unequal volume "EEI": diagonal, equal volume and shape "VEI": diagonal, varying volume, equ
...
One or more of the following:
  • dof
{ The degrees of freedom for the prior on the variance. The default is d + 2, where d is the dimension of the data. } scale

Value

  • A list giving the prior degrees of freedom, scale, shrinkage, and mean.

References

C. Fraley and A. E. Raftery (2005, revised 2009). Bayesian regularization for normal mixture estimation and model-based clustering. Technical Report, Department of Statistics, University of Washington.

C. Fraley and A. E. Raftery (2007). Bayesian regularization for normal mixture estimation and model-based clustering. Journal of Classification 24:155-181.

C. Fraley and A. E. Raftery (2006, revised 2010). MCLUST Version 3 for R: Normal Mixture Modeling and Model-Based Clustering, Technical Report no. 504, Department of Statistics, University of Washington.

C. Fraley and A. E. Raftery (2002). Model-based clustering, discriminant analysis, and density estimation. Journal of the American Statistical Association 97:611-631.

Details

defaultPrior is a function whose default is to output the default prior specification for EM within MCLUST. defaultPrior can be used to specify alternative prior parameters for a conjugate prior.

See Also

mclustBIC, me, mstep, priorControl

Examples

Run this code
# default prior
irisBIC <- mclustBIC(iris[,-5], prior = priorControl())
summary(irisBIC, iris[,-5])

# equivalent to previous example
irisBIC <- mclustBIC(iris[,-5], 
                     prior = priorControl(functionName = "defaultPrior"))
summary(irisBIC, iris[,-5])

# no prior on the mean; default prior on variance
irisBIC <- mclustBIC(iris[,-5], prior = priorControl(shrinkage = 0))
summary(irisBIC, iris[,-5])

# equivalent to previous example
irisBIC <- mclustBIC(iris[,-5], prior =
                     priorControl(functionName="defaultPrior", shrinkage=0))
summary(irisBIC, iris[,-5])

defaultPrior( iris[-5], G = 3, modelName = "VVV")

Run the code above in your browser using DataLab