Pargo Parcels -- ML Models Visual Portfolio

15 models | Plots generated from 200K synthetic records | Snowflake + Scikit-learn + XGBoost + LightGBM

Summary Dashboard

00 -- ML Portfolio Summary Dashboard (AUC comparison, score distributions, province analysis)

ML Summary Dashboard
Plot not yet generated -- run train_all_models.py --sample
RTS Risk Classification (5 classifiers + ensemble)

01 -- ROC Curves: Logistic Regression | Random Forest | XGBoost | LightGBM | Decision Tree

ROC Curves

02 -- XGBoost Feature Importances (top 15 features for RTS prediction)

Feature Importance

03 -- Best Classifier Confusion Matrix (actual vs predicted RTS/Collected)

Confusion Matrix

05 -- SVM (LinearSVC) Confusion Matrix

SVM CM
Neural Network

04 -- MLP Training Loss Curve + Validation Score

MLP Loss
Delivery Time Regression (Ridge Regression)

06 -- Ridge Regression: Residuals vs Predicted + Residual Distribution (Transit Hours)

Ridge Residuals
Customer Segmentation (K-Means)

07 -- Elbow Plot + Silhouette Scores (k=2 to k=8)

Elbow

08 -- Customer Segments in PCA 2D Space (k=5 clusters)

Segments

09 -- Segment Profile Heatmap (normalised feature means per segment)

Heatmap
Anomaly Detection (Isolation Forest)

10 -- Anomaly Score Distribution with 5th Percentile Threshold

Anomaly Scores

11 -- Anomaly vs Normal Feature Distributions (Value | Transit | Exceptions)

Anomaly Features
Return Reason Classification (Naive Bayes)

12 -- Naive Bayes Confusion Matrix (Low Risk | Dwell Risk | Exception Risk)

Naive Bayes CM
Demand Forecasting (ARIMA / Holt-Winters + Prophet Decomposition)

13 -- Holt-Winters Forecast (30 months train, 6 months forecast with 95% CI)

Forecast

14 -- Prophet-Style Decomposition: Observed | Trend | Seasonal (12-month cycle)

Decomposition
Customer Churn Prediction (LightGBM)

15 -- LightGBM Churn Feature Importances

LGB Importance

16 -- Calibration Curve: Predicted Probability vs Actual Fraction of Positives

Calibration
Customer Lifetime Value (CLV) -- XGBoost Regressor

17 -- CLV Distributions: Historical vs Annualised vs Predicted (1yr)

CLV Distributions

18 -- Mean CLV by Province (bar + map overlay)

CLV by Province

19 -- CLV Decile Analysis: top 20% customers = 69.9% of total value

CLV Deciles

20 -- CLV vs Churn Risk Matrix (tier segmentation)

CLV Churn Matrix

21 -- XGBoost CLV Feature Importance (R²=0.987, MAE=R50)

CLV Feature Importance
Geographical Analysis -- SA Province Map

22 -- SA Province Customer Density Map + CLV vs RTS Rate by Province

SA Province Map

23 -- Province Performance Dashboard: Customer Count | Mean CLV | RTS Rate

Province Detail
Correlation & Statistical Analysis

30 -- Full Feature Correlation Matrix (Pearson r, all parcel & customer attributes)

Correlation Matrix

31 -- Feature vs RTS Target Correlation Bar Chart (which features drive RTS)

Feature-Target Correlation

32 -- Scatter Matrix: Top 4 Predictive Features vs RTS (Collected vs RTS colour-coded)

Scatter Matrix

33 -- Province x Feature Heatmap: Mean values by province with RTS % column

Province Feature Heatmap

34 -- RTS Rate by Retailer Category and Province (with significance bands)

RTS by Category Province

35 -- Feature Distributions: RTS vs Collected (KS test statistic per feature)

Feature Distributions

36 -- CLV Correlations: Feature impact on Historical vs Predicted 1-Year CLV

CLV Correlations

37 -- Time-Series Correlation: ACF, Seasonal Volume, Lag-12 Scatter

Time-Series Correlation

38 -- Multi-Feature Relationship Scatter Matrix (colour = RTS risk, trend line = Pearson r)

Multi-Feature Relationships
All 15 Models -- Inventory