# Gaussian Mixture Models

Cluster based on Gaussian mixture models using the Expectation-Maximization algorithm

Gaussian mixture models (GMMs) assign each observation to a cluster by maximizing the posterior probability that a data point belongs to its assigned cluster. Create a GMM object `gmdistribution` by fitting a model to data (`fitgmdist`) or by specifying parameter values (`gmdistribution`). Then, use object functions to perform cluster analysis (`cluster`, `posterior`, `mahal`), evaluate the model (`cdf`, `pdf`), and generate random variates (`random`).

## Functions

expand all

 `fitgmdist` Fit Gaussian mixture model to data `gmdistribution` Create Gaussian mixture model
 `cdf` Cumulative distribution function for Gaussian mixture distribution `cluster` Construct clusters from Gaussian mixture distribution `mahal` Mahalanobis distance to Gaussian mixture component `pdf` Probability density function for Gaussian mixture distribution `posterior` Posterior probability of Gaussian mixture component `random` Random variate from Gaussian mixture distribution

## Topics

Cluster Using Gaussian Mixture Model

Partition data into clusters with different sizes and correlation structures.

Cluster Gaussian Mixture Data Using Hard Clustering

Implement hard clustering on simulated data from a mixture of Gaussian distributions.

Cluster Gaussian Mixture Data Using Soft Clustering

Implement soft clustering on simulated data from a mixture of Gaussian distributions.

Tune Gaussian Mixture Models

Determine the best Gaussian mixture model (GMM) fit by adjusting the number of components and the component covariance matrix structure.