End-to-end customer analytics project — RFM segmentation, churn modelling & satisfaction analysis on 35,000 Nigerian betting platform customers. Built with Python, SQL Server & Logistic Regression.
# BetAnalytics Nigeria — Customer RFM Analysis
> An end-to-end customer analytics project analysing 35,000 customers on a Nigerian betting/gaming platform — combining RFM segmentation, churn modelling, and satisfaction analysis to generate actionable business insights.
---
## Project Overview
This project simulates a real-world analytics engagement for a Nigerian betting platform. It covers the full analytics pipeline from synthetic data generation to statistical modelling and dashboard visualisation.
**Business questions answered:**
- Who are our most valuable customers and what do they look like?
- Which customers are about to churn — and can we predict it?
- Does customer satisfaction differ significantly across RFM segments?
- What is the relationship between spending behaviour and NPS?
- What operational issues are driving customer dissatisfaction?
---
## Dataset
| Table | Rows | Description |
|---|---|---|
| `dim_customer` | 35,000 | Demographics, archetype, NPS, churn label |
| `fact_bets` | 1,355,371 | Every bet — date, type, stake (₦), odds, outcome |
| `fact_transactions` | 535,019 | Deposits and withdrawals with status and processing time |
| `dim_support` | 37,401 | Support tickets with CSAT scores and resolution time |
| `dim_date` | 1,461 | Calendar table 2021–2024 |
**Nigerian market context:** NGN currency · 30 states · Football, Virtual Sports, Casino, Live Betting · Opay, Flutterwave, Paystack, PalmPay payment methods
---
## Project Architecture
```
Layer 1 — Data Generation (Python)
↓
Layer 2 — SQL Server Star Schema (SQL + SQLAlchemy)
↓
Layer 3 — RFM Scoring & Segmentation (SQL)
↓
Layer 4 — Statistical Analysis (Python)
↓
Layer 5 — Dashboard & Visualisation (HTML / Power BI)
```
---
## RFM Segments & Results
| Segment | Customers | Churn Rate | Avg NPS | Avg Monetary |
|---|---|---|---|---|
| Champions | 8,915 | 0% | 37.6 | ₦1.55M |
| Lost | 8,603 | 100% | 8.0 | ₦3,278 |
| Loyal Customers | 6,556 | 7.3% | 24.8 | ₦118K |
| At R …