Skip to content

A data-driven project that consists of data preprocessing, exploratory data analysis, and advanced analytical techniques including clustering, customer lifetime value analysis, and market basket analysis providing valuable insights into customer behaviors and sales patterns.

Notifications You must be signed in to change notification settings

ChitharaKarunasekera/Python-Customer-Segmentation-Analysis

Repository files navigation

Customer Segmentation Analysis

This notebook offers a comprehensive analysis of wholesale customer data with the aim of deriving actionable insights for business strategy. The notebook encompasses several key sections.

Every segment is intended to offer evaluations of customer behavior, spending patterns, and potential strategies for enhancing customer engagement and business performance. This analysis allows for a holistic understanding of the dataset and supports data-driven decision-making. The notebook consists of,

  • Data Preprocessing and Exploration

  • Exploratory Data Analysis (EDA): Visualize relationships between variables and understand the distributions

  • Identify Patterns and Relationships: Pair plot and correlation heatmap to analyze relationships and patterns in the data.

  • Using the K-Means algorithm for customer segmentation based on spending patterns.

  • Analyzing and interpreting cluster characteristics.

  • Visualizing clusters with pair plots and PCA (Principal Component Analysis).

  • Customer Lifetime Value (CLV) Analysis: Identifying and visualizing top customers based on spending.

  • Analysis of total expenditure across different product categories to identify key revenue drivers.

  • Market Basket Analysis (Apriori algorithm): To discover frequently bought together items for cross-selling and upselling strategies.

Usage

The notebook Customer_Segmentation_and_Sales_Analysis.ipynb contains the following steps:

  1. Data Loading: Load the wholesale customer data.
  2. Data Preprocessing: Clean and preprocess the data, including scaling and handling missing values.
  3. Exploratory Data Analysis (EDA): Visualize data distributions, correlations, and relationships.
  4. Feature Selection: Select relevant features based on correlation analysis.
  5. Clustering: Apply K-Means clustering to segment customers.
  6. Model Evaluation: Evaluate clustering performance using silhouette score and visualize clusters using PCA.
  7. Results Interpretation: Analyze the characteristics of each cluster and derive insights.
  8. Principal Component Analysis (PCA)
  9. Customer Lifetime Value (CLV) Analysis
  10. Visualize top customers
  11. Analysis of total expenditure across different products
  12. Market Basket Analysis using Apriori Algorithm

Dataset used

About

A data-driven project that consists of data preprocessing, exploratory data analysis, and advanced analytical techniques including clustering, customer lifetime value analysis, and market basket analysis providing valuable insights into customer behaviors and sales patterns.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published