In EM for a Gaussian mixture with weights , means and covariances , how do you derive the M-step updates for , and from the expected complete-data log-likelihood?
Unsupervised learning, Gaussian mixtures
Level L3 Intermediate. Length Long. Nature Mat Mathematical.
What's being asked
Whether you can maximise using responsibilities, with a Lagrange multiplier for the weights.
Key idea
With responsibilities fixed from the E-step, the M-step maximises . Each parameter group separates and gives a weighted version of the usual Gaussian maximum-likelihood estimate.
Steps
- Start from the complete-data log-likelihood . Replace the unknown indicator by its expectation to get above.
- Weights: maximise subject to . The Lagrangian is . Setting the derivative to zero gives , where . Summing over gives , so .
- Means: the part of is . Its gradient is . Setting it to zero gives .
- Covariances: the part is . Differentiating in gives , the weighted sample covariance.
- Each M-step cannot decrease the observed-data likelihood, because is a lower-bound surrogate that touches the likelihood at the current parameters.
Common mistakes
- Forgetting the constraint and the Lagrange multiplier.
- Using the old in the covariance update. Use the new from the same M-step.
- Ignoring that the likelihood is unbounded: if a component collapses onto a single point, . Add a small ridge to the covariance.
How long your answer should be
One page; 6–8 minutes.
Last checked on 4 December 2026.
Read this
Previous in Unsupervised learning: A 1-D Gaussian mixture has two components with equal weights , means and , and both variances equal to 1. For the data , what are the E-step responsibilities and the updated weights and means after one EM iteration?
Next in Unsupervised learning: A graph on four nodes has edge weights , , and no other edges. Write the unnormalised Laplacian and find its second-smallest eigenvalue and eigenvector. What clustering does the sign of that eigenvector give, and how does the eigenvalue compare with the RatioCut of that split?