added 3d kmeans