# Ghana Inflation Forecasting. A Machine Learning Study
> **Can machine learning outperform traditional econometrics for inflation forecasting during a crisis?**
> This project answers that using 120 months of Ghanaian macroeconomic data; including the 2022 crisis where prices peaked at **54.1% YoY**.
---
## 1. Executive Summary
Ghana's inflation surged from ~7% in 2019 to a peak of **54.1% in December 2022**, driven by cedi depreciation, fuel price shocks, and fiscal pressures. This project benchmarks **13 forecasting models** on monthly CPI data from January 2015 to December 2024.
The best model, **Bayesian Ridge**, achieved an **R² of 0.919** and reduced forecast error by **72.9%** compared to the SARIMAX-GARCH baseline on the unseen 2023–2024 test period.
| Model | RMSE | MAPE | R² |
|---|---|---|---|
| Bayesian Ridge | 3.04 | 9.1% | **0.919** |
| Rolling XGBoost | 3.24 | **7.8%** | 0.907 |
| Weighted Blend | 3.43 | 10.1% | 0.896 |
| Huber Regression | 4.68 | 13.7% | 0.807 |
| Elastic Net | 4.99 | 16.6% | 0.780 |
| XGBoost | 5.90 | 15.3% | 0.693 |
| Random Forest | 8.23 | 26.9% | 0.402 |
| SARIMAX-GARCH *(baseline)* | 11.18 | 29.2% | -0.103 |
| SVR | 12.41 | 22.0% | -0.358 |
---
## 2. Business Problem
The **Bank of Ghana** and economic policymakers rely on inflation forecasts to set the Monetary Policy Rate, issue forward guidance to banks and households, and plan fiscal interventions before inflation spirals out of control.
**The core challenge:** Traditional models (ARIMA, SARIMAX-GARCH) are calibrated on historical data and assume a stable relationship between variables. Ghana's 2022–2024 crisis represented a **2.3× regime shift**. The test period mean (31.6%) was more than double the training period mean (13.7%). Static models trained on pre-crisis data fail in this environment.
**Key question answered:** Which forecasting approach (traditional or ML) best handles a sudden inflation regime shift with only 83 training observations?
---
## 3. Met …