logdens: Log Density for Gaussian Mixture Model

Description Usage Arguments Details Value References See Also Examples

View source: R/logdens.R

Description

Computes the log density for observations in a univariate or multivariate Gaussian mixture model with spherical or diagonal (co)variance that varies across components.

Usage

1
logdens( x, simData, shrink = 1)

Arguments

x

A numeric vector or matrix for which the log density is to be computed.

simData

Observations from a call to simData, which includes the partition centroids and variance information for the underlying simulation model.

shrink

Shrinkage parameter for the mixture model variance. To be consistent with the shrinkage as described in partProb, the variance is scaled by the square of shrink. The default value is shrink = 1, so that no shrinkage is applied to the variance.

Details

If either radius = 0, or simData returns only centroids (nsim = 0), then no density estimate is attempted.

Value

A vector giving the log density of x in the model as specified by simData, with optional shrinkage applied to the variance.

References

G. Celeux and G. Govaert, Gaussian Parsimonious Mixture Models, Pattern Recognition, 1995.

G. J. McLachlan and D. Peel, Finite Mixture Models, Wiley, 2000.

C. Fraley and A. E. Raftery, Model-based clustering, discriminant analysis and density estimation, Journal of the American Statistical Association, 2002.

See Also

partProb

Examples

1
2
3
4
 lead <- leader(faithful)
 sim <- simData( lead)

 logdens( faithful, sim)

probout documentation built on Feb. 11, 2022, 5:10 p.m.