Skip to content

NituY/Customer-Segmentation-Analysis-with-Python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Customer-Segmentation-Analysis-with-Python

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