Skip to content

NituY/Clustering-Techniques-for-the-any-customer-dataset-using-machine-Learning

Repository files navigation

Clustering-Techniques-for-the-any-customer-dataset-using-machine-Learning

In this code, we first load the customer dataset and select the features for clustering ('Age', 'Income', and 'Spending Score'). Then, we standardize the features to ensure they have the same scale. We use the Elbow Method to find the optimal number of clusters (k) based on the inertia (sum of squared distances within each cluster). We plot the Elbow Method graph to visually identify the best k value.

image

Next, we apply K-Means clustering with the chosen k value and assign cluster labels to each customer. Finally, we visualize the clusters in a 2D scatter plot using 'Income' and 'Spending Score' as the x and y-axis, respectively.

image

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published