Logo Lanfrica

Alex-Agbey/ghana-ecommerce-analytics

Domain:

socioeconomic

Record type:

dataset
Creator:
Ale
Host:
# GhanaCart E-Commerce Sales Analytics Pipeline > A production-style ETL data pipeline that ingests, cleans, models, > and analyses 2 years of e-commerce sales data for a Ghana-based retailer. --- ## Business Problem GhanaCart operates across Accra, Kumasi, and Takoradi. Their raw sales data lived in disconnected CSV files with duplicate records, missing values, and inconsistent formatting — making reliable reporting impossible. This pipeline solves that by: - Automatically cleaning and validating raw data every run - Loading clean data into a structured SQLite data warehouse - Running analytical queries to answer 4 key business questions - Generating charts and an Excel report with one command --- ## Architecture ``` Raw CSVs (data/raw/) | v [TRANSFORM] clean_customers() / clean_products() / clean_orders() | v Processed CSVs (data/processed/) | v [LOAD] Star Schema: fact_orders + dim_customers + dim_products + dim_date | v SQLite Warehouse (data/warehouse/ghana_ecommerce.db) | v [ANALYSE] 4 charts + Excel report | v reports/charts/ + reports/excel/ ``` --- ## Data Pipeline Stats | Metric | Value | |---|---| | Raw orders | 6,050 (including 50 intentional duplicates) | | After deduplication | 6,000 | | Delivered orders | ~4,200 (70% delivery rate) | | Customers | 400 | | Products | 34 across 5 categories | | Date range | Jan 2023 – Dec 2024 | | Null values fixed | 30 total_amount values recalculated | --- ## Key Business Insights 1. **Electronics dominates** — accounts for ~55% of total revenue despite being only 24% of products 2. **Mobile Money** is the most used payment method (~40% of transactions) reflecting Ghana payment landscape 3. **Q4 peaks** — November and December consistently show 30-40% higher revenue than Q1 average 4. **Accra customers** have 2.3x higher average lifetime value than customers in other cities --- ## Tech Stack | Tool | Purpose | |---| …

Languages