mvnpEM {mixtools} | R Documentation |
EM-like Algorithm for Nonparametric Mixture Models with Conditionally Independent Multivariate Component Densities
Description
An extension of the original npEM
algorithm, for mixtures
of multivariate data where the coordinates of a row (case)
in the data matrix are assumed to be made of independent but multivariate blocks (instead of just coordinates),
conditional on the mixture
component (subpopulation) from which they are drawn (Chauveau and Hoang 2015).
Usage
mvnpEM(x, mu0, blockid = 1:ncol(x), samebw = TRUE,
bwdefault = apply(x,2,bw.nrd0), init = NULL,
eps = 1e-8, maxiter = 500, verb = TRUE)
Arguments
x |
An |
mu0 |
Either an |
blockid |
A vector of length |
samebw |
Logical: If |
bwdefault |
Bandwidth default for density estimation,a simplistic application of the
default |
init |
Initialization method, based on an initial |
eps |
Tolerance limit for declaring algorithm convergence. Convergence
is declared whenever the maximum change in any coordinate of the
|
maxiter |
The maximum number of iterations allowed; convergence
may be declared before |
verb |
Verbose mode; if TRUE, print updates for every iteration of the algorithm as it runs |
Value
mvnpEM
returns a list of class mvnpEM
with the following items:
data |
The raw data (an |
posteriors |
An |
lambda |
The sequence of mixing proportions over iterations. |
blockid |
The |
samebw |
The |
bandwidth |
The final bandwidth matrix
after convergence of the algorithm.
Its shape depends on the |
lambdahat |
The final mixing proportions. |
loglik |
The sequence of pseudo log-likelihood values over iterations. |
References
Benaglia, T., Chauveau, D., and Hunter, D. R. (2009), An EM-like algorithm for semi- and non-parametric estimation in multivariate mixtures, Journal of Computational and Graphical Statistics, 18, 505-526.
Benaglia, T., Chauveau, D. and Hunter, D.R. (2011), Bandwidth Selection in an EM-like algorithm for nonparametric multivariate mixtures. Nonparametric Statistics and Mixture Models: A Festschrift in Honor of Thomas P. Hettmansperger. World Scientific Publishing Co., pages 15-27.
Chauveau, D., and Hoang, V. T. L. (2015), Nonparametric mixture models with conditionally independent multivariate component densities, Preprint under revision. https://hal.archives-ouvertes.fr/hal-01094837
See Also
Examples
# Example as in Chauveau and Hoang (2015) with 6 coordinates
## Not run:
m=2; r=6; blockid <-c(1,1,2,2,3,3) # 3 bivariate blocks
# generate some data x ...
a <- mvnpEM(x, mu0=2, blockid, samebw=F) # adaptive bandwidth
plot(a) # this S3 method produces 6 plots of univariate marginals
summary(a)
## End(Not run)