I spent the last few weeks building an end-to-end analytics project for a fictional Kenyan lender: from 45 messy CSV files to a Power BI dashboard.
The brief: the loan book grew 3.4× in two years. Leadership wanted four answers:
→ Is the growth safe?
→ Who will default?
→ How much fraud is being missed?
→ Who are the customers?
What I found:
• One product is 42% of lending but 63% of write-offs
• 30 days late is the point of no return: 57% of late loans recover before it, 18% after
• A scorecard that would cut the bad-loan rate from 12.5% to 9.0%
• Fraud rules that catch 68% more fraud with the same review team
Stack: PostgreSQL, SQL, Python (pandas, scikit-learn), Power BI.
The data is synthetic, generated with deliberate defects and a hidden answer key, so I could score every step of my work.
The full slides are attached. Code, write-ups and the dashboard are on GitHub (link in the first comment).
If you could ask this bank one more question, what would it be?
#DataAnalytics #PowerBI #SQL #CreditRisk #PortfolioProject
PrimeBank: Financial Intelligence, Credit Risk & Fraud Analytics Platform
An end-to-end analytics build on a 2.5-million-row banking dataset: raw CSVs → validated PostgreSQL warehouse → credit-risk and fraud analysis → default-prediction model → Power BI dashboard.
PostgreSQL · SQL · Python (pandas, scikit-learn) · Power BI / DAX · Data quality engineering · Dimensional modelling · Credit risk · Fraud analytics
Short on time? Read the one-page executive summary (PDF) .
Power BI dashboard
Five pages, each answering one business question. File: PrimeBank Financial Analytics Dashboard.pbix · all pages as PDF .
Executive Overview: Is the business growing, and is it growing safely?

Credit Risk: Where is the risk, and is it getting worse?

Fraud: How much fraud are we missing, and what would the new rules catch?

Customers: Who are our customers, and which segments matter most?

Data Quality: Can we trust these numbers?

Selected visuals


Scorecard: default rate falls from 34.6% (band E) to 1.5% (A+)
Calibration: predicted vs actual default by decile


Default drivers (standardised coefficients)
Customer segment profiles
How I worked: the decisions that matter
Most of the value in this project came from not accepting the first answer. A few examples:
I changed an agreed policy when the data contradicted it. The plan counted partial payments as past due. Testing against the bank's own loan statuses showed it would mislabel 14,087 healthy loans as defaulted. The revised rule reproduces the bank's recorded status for all 60,000 loans.
I caught a misleading early-warning signal. Partial payers appeared to default less (5% vs 17%). That was exposure bias; with timing controlled, the effect disappears (1.66% vs 1.68%).
I tested a hypothesis honestly and reported that it failed. I expected transaction cash-flow data to improve SME risk prediction. The bootstrap test showed no gain, and the recommendation was changed accordingly.
I kept the answer key out of design. Fraud rules came only from the bank's own review outcomes. Ideas informed by the answer key are reported separately as hypotheses to validate.
I diagnosed instead of shrugging. When segments didn't match the hidden archetypes (ARI 0.015), a supervised ceiling test and the generator code showed the archetypes are defined by repayment conduct, not transactions. A conduct-based version improved agreement ninefold.
I set selection rules before seeing results. The model family (logistic regression unless boosting won by more than 0.010 AUC) and the number of clusters (best silhouette for k = 3–6) were both fixed in advance.
0 likes · 2 views · Nov 26, 2026
Built an end-to-end banking analytics platform covering data quality, credit risk, default prediction, fraud analysis, customer segmentation, and a five-page da