Course contentsShow
← Machine Learning and Deep Learning
Lesson 358 of 3,5388. Unsupervised Learning: ClusteringFree lesson

Ward's Linkage and Variance Minimization

Understanding Ward's method that minimizes within-cluster variance at each merge for compact clusters.

Ward's Linkage and Variance Minimization

What you'll learn: How Ward's method creates tight, compact clusters by minimizing the total within-cluster variance at every merge step.

The Core Idea

You've seen single, complete, and average linkage — all based on measuring distances between points or clusters. Ward's linkage takes a fundamentally different approach: at each step, it merges the two clusters that result in the smallest increase in total within-cluster variance.

Think of it like organizing boxes in a warehouse. Instead of grouping boxes by how close their edges are (distance-based), Ward's method groups them to keep each section as "organized" and compact as possible — minimizing the mess (variance) within each storage area.

How It Works

Within-cluster variance measures how spread out points are from their cluster's center (mean). Ward's method:

  1. Considers all possible pairs of clusters
  2. For each pair, calculates what the new total variance would be if they merged
  3. Chooses the merge that adds the least variance to the system

This greedy approach naturally produces spherical, evenly-sized clusters because merging very different or spread-out groups would spike the variance.

Why It Matters

Ward's linkage is often the default choice for hierarchical clustering because it tends to produce balanced, well-separated clusters. It works especially well when your data naturally forms compact, roughly equal-sized groups — similar to what K-Means looks for, but without needing to specify K upfront.

The tradeoff? It assumes roughly spherical clusters and can struggle with elongated or irregular shapes (just like K-Means).

Key Takeaway: Ward's linkage merges clusters by minimizing within-cluster variance at each step, producing compact, balanced clusters ideal for spherical group structures.