Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save n0obcoder/4af01667522c0445526590a0034d840e to your computer and use it in GitHub Desktop.
Save n0obcoder/4af01667522c0445526590a0034d840e to your computer and use it in GitHub Desktop.
# setting the color of all the data points to 'Gray' at the beginning
initial_data_point_color = 'Gray'
display_kcenters(kcenters)
plt.scatter(x_data, y_data, color = initial_data_point_color)
plt.title('before kMeans Clustering')
plt.xlabel('Some Feature x')
plt.ylabel('Some Feature y')
plt.grid()
plt.savefig(results_dir + '/before_kmeans.jpg')
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment