Skip to content
EduCS
← Machine learning

A4.3.4 HL · unsupervised learning

k-means clustering

With no labels at all, k-means finds groups by guessing k centres, then repeating two simple moves: colour each point by its nearest centre, and slide each centre to the middle of its points. Watch it settle, and re-seed to see it land somewhere new.

The ringed crosses are the cluster centres. Each step recolours points to their nearest centre, then moves each centre to the middle of its points. Click to add a point.