...

/

Finding the Optimal Number of Clusters

Finding the Optimal Number of Clusters

Learn how to calculate and choose the optimal number of clusters based on our data.

We will now see the options we have in choosing the optimal number of clusters and what that entails, but let’s first take a look at the following screenshot to visualize how things progress from having one cluster to eight clusters:

Press + to interact
Data points and cluster centers for all possible cluster numbers
Data points and cluster centers for all possible cluster numbers

We can see the full spectrum of possible clusters and how they relate to data points. At the end, when we specified “8,” we got the perfect solution in which every data point is a cluster center.

In reality, we might not want to go for the full solution, for two main reasons.

  • Firstly, it is probably going to be prohibitive from a cost perspective. Imagine making 1,000 T-shirts with a few hundred sizes.
  • Secondly, in practical situations, it usually wouldn’t add much value to add more clusters after a certain fit has been achieved.

Using our T-shirt example, imagine if we have two people with sizes 5.3 ...