How can you handle an empty cluster if one arises during K-Means iterations?

Last updated 11 November 2026

  • An empty cluster has an undefined mean, so re-seed its centroid. The common choice is the point farthest from its assigned centroid (scikit-learn's approach), or a point from the highest-SSE cluster.

  • Other options: keep the old centroid, drop to k−1 clusters, or restart with new initialization.

  • Prevent it with k-means++ seeding from real data points and outlier removal. Frequent empty clusters suggest k is too large.

  • https://github.com/aeon-toolkit/aeon/blob/main/aeon/clustering/_k_means.py
  • https://robinsonraju.blog/General-Notes/Text-Books/Introduction-to-Data-Mining
  • https://medium.com/ai-made-simple/k-means-clustering-e9bd722a09fa
All Clustering interview questions