Skip to content

FRM Part I · FRM Exam Part I · Machine Learning and Prediction

In a K-means run with K = 2, five one-dimensional observations are 1, 2, 4, 9 and 10. The initial centroids are 2 and 9. After assigning each point to the nearest centroid and recomputing the centroids once, what are the new centroids?

The new centroids are 2.33 and 9.50. Points 1, 2 and 4 are nearest the centroid at 2, giving a mean of 2.33, while 9 and 10 are nearest the centroid at 9, giving a mean of 9.5.

  1. A1.5 and 9.5
  2. B2.33 and 9.50Correct
  3. C2.00 and 9.00
  4. D2.33 and 10.00

Explanation

Distances: 1 and 2 are closest to 2; 4 is 2 from centroid 2 and 5 from centroid 9, so it goes with 2. 9 and 10 go with 9. New centroids: (1+2+4)/3 = 2.33 and (9+10)/2 = 9.5. The option 1.5 and 9.5 wrongly leaves out the point 4.

Did you get it right without looking?

One question tells you little. A timed set on Machine Learning and Prediction shows your real accuracy, how long you take and where you lose marks.

More Machine Learning and Prediction questions