Hari Babu C H

Project Case Study
2024

Superstore Sales Analytics:
End-to-End Data Analytics
Pipeline

9,800
Records Cleaned
4,922
Orders Analysed
$2.26M
Total Revenue
Superstore Sales Analytics: An End-to-End Data Analytics Pipeline with Python, SQL & Streamlit

This project delivers a complete data analytics pipeline on the US Superstore Sales dataset (2015–2018), covering every stage from raw ingestion to interactive business intelligence. The raw CSV was cleaned and enriched using a reproducible Python pipeline, yielding 9,800 records with 33 engineered features including profit margin, shipping days, unit price, and sales bands. The cleaned data was then interrogated with 30+ structured SQL business queries and explored through three Jupyter notebooks (Data Cleaning, EDA, and Visualisation). A fully interactive Streamlit dashboard surfaces KPI cards, trend charts, category breakdowns, a regional choropleth, and auto-generated narrative insights — with live CSV upload and filtered data export. The project spans three product categories across four US regions and 793 unique customers, generating $2.26M in revenue and $103K in profit over four years.

  • Build a reproducible data-cleaning pipeline that transforms raw sales CSV into analysis-ready data
  • Engineer business-critical features: profit margin, shipping days, unit price, and sales bands
  • Answer 30+ real-world business questions using structured SQL queries
  • Conduct thorough exploratory data analysis across categories, regions, and time
  • Deliver an interactive Streamlit dashboard with filters, KPIs, and downloadable insights

A modern data analytics stack was used to build an efficient, reproducible, and interactive end-to-end pipeline:

Python (Jupyter Notebook) Pandas & NumPy Matplotlib & Seaborn Plotly (Interactive Charts) Streamlit (Dashboard) SQL (ANSI / MySQL 8 / PostgreSQL)
  • Data ingestion, type coercion, and missing-value imputation at scale
  • Feature engineering: profit margin %, unit price, shipping days, sales bands
  • SQL-driven business analysis — revenue, profitability, segmentation, and trend queries
  • Exploratory data analysis across categories, regions, segments, and time dimensions
  • Interactive dashboard development with filters, KPI cards, and map visualisations
Repository Layout
📁 sales/
└── 📂 Data-Analytics-Project/
    ├── 📂 Dataset/
    │   ├── Raw_Data.csv          ← Original Superstore CSV (~9,800 rows)
    │   └── Cleaned_Data.csv      ← 33-column enriched dataset
    ├── 📂 Python/
    │   ├── clean_pipeline.py     ← Standalone cleaning script
    │   ├── Dashboard.py          ← Streamlit dashboard app
    │   ├── Data_Cleaning.ipynb   ← Step-by-step cleaning notebook
    │   ├── Data_Visualization.ipynb ← Chart & plot notebook
    │   ├── EDA.ipynb             ← Exploratory data analysis notebook
    │   └── Requirements.txt      ← Python dependencies
    └── 📂 SQL/
        ├── Business_Queries.sql  ← 30+ business questions with insights
        ├── Data_Cleaning.sql     ← SQL-based staging & cleaning pipeline
        └── EDA.sql               ← SQL exploratory analysis
Project Visuals

A visual walkthrough of the analysis outputs — from the Streamlit KPI dashboard to SQL business queries and Python EDA charts.

Streamlit KPI Dashboard
Streamlit KPI Dashboard
Sales Trend & Category Charts
Revenue Trend & Category Analysis
SQL Business Queries Output
SQL Business Queries & Insights
What the Data Revealed

The cleaned dataset of 9,800 records spanning 4,922 orders across 793 customers and 1,861 products yielded clear business signals. Technology and Furniture dominate top-line revenue, yet Furniture lags in profitability — exposing a margin inefficiency. A handful of sub-categories (notably Tables and Bookcases) are chronically loss-making, while a small cluster of hero products drives outsized revenue. The West and East regions outperform Central and South on both revenue and margin. The Streamlit dashboard's regional choropleth and correlation heatmap make these disparities immediately actionable for business stakeholders, and the auto-generated narrative insights surface recommendations directly within the interface.

This project demonstrates how a disciplined, end-to-end analytics pipeline — from raw CSV to interactive dashboard — can transform transactional retail data into strategic business intelligence. By combining Python-based data engineering, SQL-driven business analysis, and a Streamlit front-end, the pipeline is both reproducible and presentation-ready. The modular structure (clean_pipeline.py, three Jupyter notebooks, three SQL scripts, and a live dashboard) means every step is auditable and extensible, making it a strong foundation for production-grade analytics or further machine learning work.