Package smile.stat.distribution
Class MultivariateGaussianMixture
java.lang.Object
smile.stat.distribution.MultivariateMixture
smile.stat.distribution.MultivariateExponentialFamilyMixture
smile.stat.distribution.MultivariateGaussianMixture
- All Implemented Interfaces:
Serializable,MultivariateDistribution
Finite multivariate Gaussian mixture. The EM algorithm is provided to learn
the mixture model from data. The BIC score is employed to estimate the number
of components.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class smile.stat.distribution.MultivariateMixture
MultivariateMixture.Component -
Field Summary
Fields inherited from class smile.stat.distribution.MultivariateExponentialFamilyMixture
bic, LFields inherited from class smile.stat.distribution.MultivariateMixture
components -
Constructor Summary
ConstructorsConstructorDescriptionMultivariateGaussianMixture(MultivariateMixture.Component... components) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionstatic MultivariateGaussianMixturefit(double[][] data) Fits the Gaussian mixture model with the EM algorithm.static MultivariateGaussianMixturefit(double[][] data, boolean diagonal) Fits the Gaussian mixture model with the EM algorithm.static MultivariateGaussianMixturefit(int k, double[][] data) Fits the Gaussian mixture model with the EM algorithm.static MultivariateGaussianMixturefit(int k, double[][] data, boolean diagonal) Fits the Gaussian mixture model with the EM algorithm.Methods inherited from class smile.stat.distribution.MultivariateExponentialFamilyMixture
fit, fitMethods inherited from class smile.stat.distribution.MultivariateMixture
bic, cdf, cov, entropy, length, logp, map, mean, p, posteriori, size, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface smile.stat.distribution.MultivariateDistribution
likelihood, logLikelihood
-
Constructor Details
-
MultivariateGaussianMixture
Constructor.- Parameters:
components- a list of multivariate Gaussian distributions.
-
-
Method Details
-
fit
Fits the Gaussian mixture model with the EM algorithm.- Parameters:
k- the number of components.data- the training data.- Returns:
- the distribution.
-
fit
Fits the Gaussian mixture model with the EM algorithm.- Parameters:
k- the number of components.data- the training data.diagonal- true if the components have diagonal covariance matrix.- Returns:
- the distribution.
-
fit
Fits the Gaussian mixture model with the EM algorithm. The number of components will be selected by BIC.- Parameters:
data- the training data.- Returns:
- the distribution.
-
fit
Fits the Gaussian mixture model with the EM algorithm. The number of components will be selected by BIC.- Parameters:
data- the training data.diagonal- true if the components have diagonal covariance matrix.- Returns:
- the distribution.
-