drag = pan · scroll = zoom
iter 0
Dot = data point (color = assignment) Halo radius = |silhouette|, green = good fit Red halo = negative silhouette (misfit)

Silhouette Score 2D: Finding the Right Number of Clusters

K-means will happily split your data into any K you ask for — this simulator shows why picking that K is a real question with a real answer. It draws a hidden mixture of Gaussian blobs on a flat scatter plot, runs Lloyd's algorithm live, and draws a colored halo around every point whose radius and color encode its silhouette coefficient: how much closer it sits to its own cluster than to its nearest rival. Sweep K from 2 to 8 and the panel plots the average silhouette for each value, exposing the peak that marks the number of clusters the data actually supports — the same diagnostic scikit-learn's silhouette_score is built on, and a sharper tool than watching inertia fall on an elbow plot. Drag to pan, scroll or pinch to zoom.