Without labels

No right answers here: find the structure in the data itself.

The curse of dimensionality

In many dimensions every point is about as far from every other.

Distances from one point to 200 others, divided by their mean

How much farther the farthest is than the nearest

With many dimensions "nearest" means little.


Principal component analysis (PCA)

The direction with the most variance is the first principal component.

The cloud and a direction

  • the direction
  • principal components

Variance along every direction

The points projected onto the direction


How many components? A scree plot

Where the bars drop to almost nothing, the rest is noise.


K-means clustering

Assign every point to its nearest centre, move every centre to its points' mean, repeat.

The points and the centres

Which k?

Look for the elbow, and for the highest silhouette.

Inertia per k: the elbow

Silhouette per k