Here's the basic k-means code; let me know if you find any problems. The
clustering depends on Model's score() function, so we won't be able to
test it directly just yet.