Skip to content
Quantoros

Do you know how K-means works?

Classic MLLevel: IntermediateClustering

Do you know how K-means works?

Hints
  • How does this method define distance and cluster shape?
  • Consider noise, the number of groups and feature scaling.

Answer

  1. Partition points into k subsets.
  2. Compute the seed points as the new centroids of the clusters of the current partitioning.
  3. Assign each point to the cluster with the nearest seed point.
  4. Go back to step 2 or stop when the assignment does not change.

Source and licence: Alexey Grigorev & contributors — Data Science Interviews · CC-BY-4.0

Related questions