Basic k-means functionality added