The way kmeans algorithm works is as follows:
1.Specify number of clusters K.
2.Initialize centroids by first shuffling the dataset and then randomly selecting K data points for the centroids without replacement.
3.Keep iterating until there is no change to the centroids. i.e assignment of data points to clusters isn’t changing.
4.Compute the sum of the squared distance between data points and all centroids.
5.Assign each data point to the closest cluster (centroid).
6.Compute the centroids for the clusters by taking the average of the all data points that belong to each cluster.
-
Notifications
You must be signed in to change notification settings - Fork 2
Bread-and-Code/K-MAENS
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description or website provided.
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published