36. K-Means Clustering in Python
36.5 Practice, Tip and Close
Why. Close when you can fit KMeans, choose a small K, and describe each group in words.
How.
Chapter practice
- Make 12 fictional Mauli Dairy shop rows: weekly_litres and SKUs_bought.
- Run KMeans for K=3.
- Print groupby means and name each cluster in one Marathi or English phrase.
- Note one reason clustering is not “accuracy %”.
Thodkyaat sangaycha tar (quick recap)
- K-Means groups rows without y
- You choose K; interpret clusters in business words
- Watch feature scales on real projects
- Useful for segments, not for labelled churn scores
Samajla ka? Next: Chapter 37 — How to check if your ML model is good.