Logo Lanfrica

Apollop24/mpesa-financial-analytics

Domaine:

socioeconomic

Type de record:

software
Créateur:
Apo
Hôte:
This is a dedecated Html File that is use to analyze Mpesa statement and other bank statememts that has the same structure as Mpesa statements # M-PESA Financial Analytics System **A complete financial intelligence system for Kenyan M-PESA statement data.** Extract transactions from PDF statements, run comprehensive financial analysis, and explore every result through an interactive browser dashboard — all in KES. --- ## What this system does This system takes your Safaricom M-PESA PDF statements and turns them into a structured financial picture. It extracts every transaction exactly as printed, removes duplicates across overlapping statement periods, computes financial metrics at every time granularity, and presents everything through a self-contained dashboard that runs in any browser with no server required. The pipeline has two parts that can be used independently or together: - **Part 1** is a Python script that reads PDF files, extracts all transactions, and writes a clean CSV. - **Part 2** is a Python analytics engine that receives the clean data and generates an Excel workbook plus an HTML dashboard. - **The standalone dashboard** accepts the CSV or the raw PDFs directly in the browser, extracting and analysing without any Python required. --- ## Repository contents ``` mpesa-analytics/ ├── mpesa_part1_extractor.py Python script: PDF to CSV extraction ├── mpesa_part2_analytics.py Python script: analytics engine and dashboard generator ├── mpesa_dashboard.html Self-contained browser dashboard (no server needed) ├── requirements.txt Python dependencies ├── .gitignore └── README.md ``` --- ## System architecture ``` Your M-PESA PDFs | v [ Part 1: Python extractor ] - Reads all PDFs in folder - Strips headers, footers, boilerplate - Assembles multi-line transaction rows - Parses receipt, date, time, details, amounts - Deduplicates across overlapping statement periods - Outputs: MPESA_verbatim_extract.csv | v [ Part 2: Analytics engine ] OR [ HTML Dashboard ] - Feature engineering - Upload CSV or PDF directly …