# Appropriate cluster in k-mean clustering

I am performing k-mean clustering on a demographic data-set. I have taken k $= 3$ and each time I run this clustering process in a software, I get different set of clusters. Now, I am not sure which result is to be considered as final. I understand why each time it produces different clusters but how do I figure out which cluster is the most appropriate one? Is this a subjective choice?

• If your question also depends on software, why don't you include the information which software you are using in your post? Oct 26, 2016 at 7:16
• No, my question doesn't depend on software. You can perform clustering (for a fixed k) any number of times in any software (matlab, mathematica) and you will get different results each time.. Oct 26, 2016 at 7:27
• k-means solution depends on the initial selection of the centriods. Agree with @Ferdi. Oct 26, 2016 at 7:28
• @L.V.Rao Exactly! that's why it gives different clusters every number of time i do clustering. I suppose this thing is common for all statistical tool which perform k-mean clustering. Oct 26, 2016 at 7:30
• @Dark_Knight all the best. Oct 26, 2016 at 8:10

You can use the clustering that minimizes the sum of variances within the clusters.

This is also used when determining the optimal $k$, in a tradeoff against $k$, since increasing $k$ will reduce the variance - but of course you can just as easily compare different clusterings with the same $k$. The $k$ term drops out, and you are essentially left with the within-cluster variance.

Alternatively, you can look at the silhouettes, which evaluates the separation of clusters. This is also commonly used to determine $k$ but can certainly be used to compare different clusterings with the same $k$.

If you get very different results every time, probably none of them is good.

If k-means works well, most seeds will yield the same result (except for enumeration of clusters).

I would try with other k values to see if the clustering results are significantly different or not. In addition, there are some centroid initialization algorithms that can eliminate the random factor, which would help you stabilize the results. For example, see this.

Also, you may want to use some internal indices to evaluate the clustering solutions.

• The question is poorly word.ed. Start by saying what kind of data you have if any. Then explain what clustering method you are looking at. It is okay to use the links after you explain the problem. Jan 12, 2017 at 6:13