changed data structure for all_states to be rows and columns instead of centroid vectors