title: Edited: K means clustering and finding points closest to the centroid
body: <p>I am trying to apply k means to cluster actors based on the information in the following columns</p>
  <pre><code>Actors              Movies  TvGuest Awards  Shorts  Special LiveShows
  Robert De Niro         111      2     6       0        0       0
  Jack Nicholson          70      2     4       0        5       0
  Marlon Brando           64      2     5       0        0       28
  Denzel Washington       25      2     3      24        0       0
  Katharine Hepburn       90      1     2       0        0       0
  Humphrey Bogart        105      2     1       0        0       52
  Meryl Streep            27      2     2       5        0       0
  Daniel Day-Lewis        90      2     1       0       71      22
  Sidney Poitier          63      2     3       0        0       0
  Clark Gable             34      2     4       0        3       0 
  Ingrid Bergman          22      2     2       3        0       4
  Tom Hanks               82     11     6      21       11      22
  </code></pre>
  <pre><code>#began by scaling my data
  X = StandardScaler().fit_transform(data)
  
  #used an elbow plot to find optimal k value  
  sum_of_squared_distances = []
  K = range(1,15)
  for k in K:
      k_means = KMeans(n_clusters=k)
      model = k_means.fit(X)
      sum_of_squared_distances.append(k_means.inertia_)
  plt.plot(K, sum_of_squared_distances, 'bx-')
  plt.show()
  
  #found yhat for the calculated k value
  kmeans = KMeans(n_clusters=3)
  model = kmeans.fit(X)
  yhat = kmeans.predict(X)
  </code></pre>
  <p>Unable to figure out create scatter plots by actors.</p>
  <p><strong>EDIT:</strong>
  Is there a way to find which actors are closest to centroids if the centroids were also plotted using</p>
  <p>centers = kmeans.cluster_centers_ (The kmeans here refers to Eric's solution below)</p>
  <p>plt.scatter(centers[:,0],centers[:,1],color='purple',marker='*',label='centroid')</p>