Data Science, Machine Learning, Artificial Intelligence, Technology, Data Mining.
mean of the original data original_means = cereal_df_encoded.mean(axis=0) # Append the mean to the centroids for comparison centroids_comparison_df = centroids_df.copy() centroids_comparison_df.loc['Mean'] = original_means # Display the comparison print(centroids_comparison_df) # Visualization