Centroid update in kdtree