2
$\begingroup$

I have a theoretical problem, I think it is easier to show it instead of talking about it:

enter image description here

So by visual examination we got 2 clusters, which k-means does not necessarily get, because some points on the edge of the bigger cluster are closer to the center of the smaller cluster than to the center of the bigger one. A possible solution would be to move closer to the second cluster with the centroid of the first cluster. I am not sure whether k-means does this (probably not), but if we have multiple small clusters around the big one, this does not help either. How could we modify the k-means to overcome this? Are there clustering algorithms, which don't have this weakness?

$\endgroup$
  • $\begingroup$ @ttnphns I have not a clue how to modify k-means to overcome this problem (probably there are many different ways to do that). If you think your proposition with rings is a possible solution, then it is just as good answer as the other, which recommends density based clustering instead. $\endgroup$ – inf3rno Mar 27 '18 at 8:58
  • $\begingroup$ Did you even read just the Wikipedia article? Or a clustering book? There is so much more than kmeans. $\endgroup$ – Has QUIT--Anony-Mousse Mar 28 '18 at 7:34
  • $\begingroup$ @Anony-Mousse I liked to learn k-means, because I watched a video about it, and it was very easy to understand what it does. On the other hand wikipedia is full of mathematical formulas usually without any good explanation, so for a beginner it is close to impossible to learn statistics/clustering from there. I bought some statistics books, but I haven't had the time to read them yet. $\endgroup$ – inf3rno Mar 28 '18 at 9:41
3
$\begingroup$

Your example looks like a textbook case where density based clustering works better. Such algorithms look for regions of high density and cluster those. The possibly best-known such algorithm is DBSCAN. We also have a tag . With decent parameterization, DBSCAN should be able to detect your two clusters.

You may also be interested in How to understand the drawbacks of K-means.

| cite | improve this answer | |
$\endgroup$
  • 1
    $\begingroup$ GMM should also work fine on above toy example, because the clusters are spherical. But yes, except for the cluster shape it is pretty much the motivational example of density based clustering... $\endgroup$ – Has QUIT--Anony-Mousse Mar 28 '18 at 7:32
  • $\begingroup$ Thanks for the link! So according to it, you have to find the right assumptions before applying any clustering algorithm otherwise the result will be a disaster. $\endgroup$ – inf3rno Mar 29 '18 at 13:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.