Question: Use the k-means algorithm and Euclidean distance to cluster the following 8 examples into 3 clusters: P 1 = (2,10), P2 = (2,5), P3 =
Use the k-means algorithm and Euclidean distance to cluster the following 8 examples into 3 clusters:
P1= (2,10), P2= (2,5), P3= (8,4), P4= (5,8), P5= (7,5), P6= (6,4), P7= (1,2), P8= (4,9).
The distance matrix based to be used on the basis of Euclidean distance is given below:
| P1 | P2 | P3 | P4 | P5 | P6 | P7 | P8 | |
| P1 | ||||||||
| P2 | ||||||||
| P3 | ||||||||
| P4 | ||||||||
| P5 | ||||||||
| P6 | ||||||||
| P7 | ||||||||
| P8 |
Suppose that the initial seeds (centers of each cluster) are P1, P3 and P8. Run the k-means algorithm for 1 epoch only. At the end of this epoch show:
- The new clusters (i.e. the examples belonging to each cluster)
- The centers of the new clusters
- Draw a 10 by 10 space with all the 8 points and show the clusters after the first epoch and the new centroids.
- How many more iterations are needed to converge? Draw the result for each epoch.
-
For the clustering you obtained at the end of the iteration above, give the mean square error of each clusterMSE(Cluster 1) =
MSE(Cluster 2) =
MSE(Cluster 3) =
MSE = Error =1 Ni=1k(xi-)2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
