gmdistribution - Construct Gaussian mixture distribution

Class

@gmdistribution

Syntax

obj = gmdistribution(MU,SIGMA,p)

Description

obj = gmdistribution(MU,SIGMA,p) constructs an object obj of the @gmdistribution class defining a Gaussian mixture distribution.

MU is a k-by-d matrix specifying the d-dimensional mean of each of the k components.

SIGMA specifies the covariance of each component. The size of SIGMA is:

p is an optional 1-by-k vector specifying the mixing proportions of each component. If p does not sum to 1, gmdistribution normalizes it. The default is equal proportions.

Reference

[1] McLachlan, G., and D. Peel. Finite Mixture Models. Hoboken, NJ: John Wiley & Sons, Inc., 2000.

Example

Create a gmdistribution object defining a two-component mixture of bivariate Gaussian distributions:

MU = [1 2;-3 -5];
SIGMA = cat(3,[2 0;0 .5],[1 0;0 1]);
p = ones(1,2)/2;
obj = gmdistribution(MU,SIGMA,p);

ezsurf(@(x,y)pdf(obj,[x y]),[-10 10],[-10 10])

See Also

fit, pdf, cdf, random, cluster, posterior, mahal

  


 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS