gaussian_mixture_mo​del.m

Estimate the parameters of a 1D Gaussian Mixture Model using the EM algorithm.

Vous suivez désormais cette soumission

A Gaussian mixture model means that each data point is drawn (randomly) from one of C classes of data, with probability p_i of being drawn from class i, and each class is distributed as a Gaussian with mean standard deviation mu_i and sigma_i. Given a set of data drawn from such a distribution, we seek to estimate these unknown parameters.

The algorithm used here for estimation is EM (Expectation Maximization). Simply put, if we knew the class of each of the N input data points, we could separate them, and use Maximum Likelihood to estimate the parameters of each class. This is the M step. The E step makes (soft) choises of (unknown) classes for each of the data points based on the previous round of parameter estimates for each class.

Implicitly the data is classfied (or clustered) into the different classes, whose parameters are estimated.

The current code only works for 1D data, and is primarily of use in illustrating the idea about mixture models and EM, but it would be pretty easy to generalize to higher dimensions.

Citation pour cette source

Matthew Roughan (2026). gaussian_mixture_model.m (https://fr.mathworks.com/matlabcentral/fileexchange/24867-gaussian_mixture_model-m), MATLAB Central File Exchange. Extrait(e) le .

Catégories

En savoir plus sur Statistics and Machine Learning Toolbox dans Help Center et MATLAB Answers

Informations générales

Compatibilité avec les versions de MATLAB

  • Compatible avec toutes les versions

Plateformes compatibles

  • Windows
  • macOS
  • Linux
Version Publié le Notes de version Action
1.1.0.0

Minor fix to improve the initial variance estimates so it can deal with widely spread data.

1.0.0.0