Clustering splits unlabeled data points into groups, so that points in the same group are similar to each other. It is a core task of unsupervised learning, since no labels tell the algorithm what the groups should be. K-means gives each point exactly one cluster. A Gaussian mixture model gives each point a probability for each cluster and models the density of the data. Hierarchical clustering builds a tree of merges, which gives a clustering for every number of clusters.
Prerequisites
- 1. Learning Paradigms, for what makes a task unsupervised.
- 3.5a Vector Norm, for the Euclidean distance that k-means minimizes.
- 6.2 Multivariate Gaussian Distribution, for the components of a mixture model.
- 1.2.1 Maximum Likelihood Estimation, for how a mixture model is fit.
- 3.11.5 EM Algorithm, for the general algorithm behind mixture-model fitting.
Contents
- 6.1. K-Means: Lloyd’s algorithm, convergence to a local minimum, k-means++ seeding, choosing , feature scaling, and the link to mixtures.
- 6.2. Gaussian Mixture Models: responsibilities, the EM updates, covariance structures, collapsing components, and choosing with BIC.
- 6.3. Hierarchical Clustering: agglomerative merging, the dendrogram, linkage choices, cutting the tree, and clustering assets by correlation.
Recommended path
Read 6.1. K-Means first, since its two alternating steps reappear as the E-step and M-step of a mixture model. Then read 6.2. Gaussian Mixture Models, and read 3.11.5 EM Algorithm for the proof that EM never lowers the likelihood. Read 6.3. Hierarchical Clustering when the number of clusters is unknown. For data with many features, read 7.1. Principal Component Analysis and 7.2. Curse of Dimensionality, since distances lose contrast in high dimensions. 9.4. Bag of Visual Words applies k-means in computer vision.