{"id":49401364,"url":"https://github.com/razalkr70/customer-segmentation-using-dataset","last_synced_at":"2026-04-28T18:04:13.952Z","repository":{"id":293185891,"uuid":"982778793","full_name":"Razalkr70/Customer-Segmentation-using-dataset","owner":"Razalkr70","description":"A data science project that segments mall customers using K-Means clustering. Based on age, income, and spending score, it identifies customer groups and visualizes them with 2D and 3D plots for targeted marketing insights.","archived":false,"fork":false,"pushed_at":"2025-05-14T04:32:52.000Z","size":391,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-14T06:05:49.183Z","etag":null,"topics":["clustering","customer-segmentation","data-science","data-visualization","kmeans","machine-learning","pca","python","scikit-learn"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Razalkr70.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-13T11:51:14.000Z","updated_at":"2025-05-14T04:34:43.000Z","dependencies_parsed_at":"2025-05-14T06:05:54.098Z","dependency_job_id":"a7636b8d-5ef8-47d8-bb8a-2ee2536601ef","html_url":"https://github.com/Razalkr70/Customer-Segmentation-using-dataset","commit_stats":null,"previous_names":["razalkr70/customer-segmentation-using-dataset"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Razalkr70/Customer-Segmentation-using-dataset","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Razalkr70%2FCustomer-Segmentation-using-dataset","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Razalkr70%2FCustomer-Segmentation-using-dataset/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Razalkr70%2FCustomer-Segmentation-using-dataset/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Razalkr70%2FCustomer-Segmentation-using-dataset/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Razalkr70","download_url":"https://codeload.github.com/Razalkr70/Customer-Segmentation-using-dataset/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Razalkr70%2FCustomer-Segmentation-using-dataset/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32392314,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-28T14:34:11.604Z","status":"ssl_error","status_checked_at":"2026-04-28T14:32:37.009Z","response_time":56,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clustering","customer-segmentation","data-science","data-visualization","kmeans","machine-learning","pca","python","scikit-learn"],"created_at":"2026-04-28T18:04:12.635Z","updated_at":"2026-04-28T18:04:13.944Z","avatar_url":"https://github.com/Razalkr70.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🛍️ Customer Segmentation using K-Means Clustering\n\nThis project performs customer segmentation on a mall customer dataset using the K-Means clustering algorithm. It identifies groups based on features like age, income, and spending score, and visualizes the clusters using pair plots and PCA in 3D.\n\n## 📌 Overview\n\nCustomer segmentation is a key technique in marketing and business analytics. In this project, the K-Means algorithm is applied to group customers based on their demographics and spending patterns.\n\n### ✨ Features\n\n- Data preprocessing and feature scaling  \n- Gender encoding  \n- Elbow method to determine optimal `k`  \n- Cluster formation using K-Means  \n- Cluster-wise statistical summary  \n- Visualizations using seaborn and matplotlib  \n- 3D PCA for better insight into clusters  \n- Customer labeling using custom logic  \n\n## 🛠️ Tech Stack\n\n- Python  \n- Pandas, NumPy  \n- Matplotlib, Seaborn  \n- Scikit-learn  \n- PCA (Principal Component Analysis)  \n \n\n## 📊 How It Works\n\n1. Dataset is preprocessed and gender is encoded.\n2. Elbow method is used to determine the optimal number of clusters.\n3. K-Means is applied to group customers.\n4. Cluster visualization using seaborn and PCA.\n5. Each cluster is labeled with intuitive names like \"Young Spenders\", \"Savers\", etc.\n\n## 📂 Dataset\n\n`Mall_Customers.csv` should be in your working directory. It contains:\n- CustomerID\n- Gender\n- Age\n- Annual Income (k$)\n- Spending Score (1-100)\n\n## 🚀 Run the Code\n\n```bash\npip install pandas numpy matplotlib seaborn scikit-learn\npython customer_segmentation.py\n```\n### 📈 Sample Output\n- Cluster visualization via pairplots\n- 3D PCA cluster plot\n- Cluster statistics\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazalkr70%2Fcustomer-segmentation-using-dataset","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frazalkr70%2Fcustomer-segmentation-using-dataset","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frazalkr70%2Fcustomer-segmentation-using-dataset/lists"}