Unsupervised Learning & Gaussian Mixture Models

preamble

Below is an implementation of EM Algorithm in Octave:

Tips:

  • Replace the inverse function with pinv if you get machine precision errors.
  • r2 is the mean matrix for both clusters.
  • data_cluster_1_cov is the covariance matrix for first cluster whereas data_cluster_2_cov is the covariance matrix for second cluster.
  • h is the label matrix for both clusters.

EMCode

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s