Forecasting Brent crude from geopolitics, sanctions and market data
Can what is known at today's close (recent price action, volatility, geopolitical risk, Iran sanctions, OPEC supply) predict where Brent goes over the next 1 or 5 trading days? We built a point-in-time dataset of 35 years and tested 52 models under strict, leakage-resistant chronological validation, then scored the frozen choice once on 2020–2025.
joint project · all three members contributed equally
Oil prices meet geopolitics
The project joins five tables into one daily master table: Brent, WTI and Dubai prices, a curated timeline of 68 market-moving geopolitical events, 25 US/EU/UN sanctions on Iran, Iran's crude exports by destination, and monthly risk indicators (Geopolitical Risk Index, VIX, dollar index, OPEC spare capacity, Strait of Hormuz closure probability).
Events and sanctions are moved to the next trading day when they fall on a weekend, and every lower-frequency series is lagged by its reporting delay: monthly indicators by one month, annual export data by one year. Nothing enters a row before it would have been public.
The source market series are synthetic but calibrated to historical levels, as their author states, and they contain long flat stretches at artificial price ceilings. Instead of deleting them, we flag every row whose features or target touch a ceiling. That gives two training populations: all rows (the complete history) and eligible rows (about 72% of days, with clean targets).
Dataset
- Period
- 2 Jan 1990 – 25 Apr 2025
- Trading days
- 9,214
- Eligible rows (1-day / 5-day)
- 6,633 / 6,613
- Geopolitical events
- 68 (25 involve Iran)
- Sanctions
- 25 (1979–2025)
Targets
- 1-day Brent return
- σ ≈ 1.8–2.0%
- 5-day Brent return
- σ ≈ 4.8–5.2%
- Largest 1-day move
- −26.0% / +16.6%
Sources
- Market and events
- Kaggle, Apache 2.0
- Real Brent spot
- U.S. EIA
44 predictors, all known at the close
From 124 candidate columns, administrative fields, raw price levels, unlagged indicators and near-duplicates (|Spearman ρ| ≥ 0.90) were removed. The remaining 44 predictors fall into seven groups:
Brent returns 1, 2, 3, 5, 10 and 20 days back
mean, volatility, average absolute move and share of up-days over 5–60 days
5–60-day momentum, distance from the 5- and 60-day moving averages
GPR index, Iran-specific risk, Hormuz closure probability and risk premium, event pulse
days since the last sanction, oil/financial sector hit, relief flag, pressure step
VIX, dollar index, OPEC production and spare capacity, US rig count
day of week, month-end flag, seasonal month term
target: yt,h = 100 · (Brentt+h / Brentt − 1), h ∈ {1, 5} · every feature on row t uses data up to Brentt only
Leakage-resistant chronological validation
No shuffling, ever. Each experiment uses four expanding validation blocks followed by a final, untouched 15% test. A training row is admitted only if its full h-day target was already observed when the evaluation block starts (record_id + h ≤ origin), so overlapping 5-day targets cannot leak across the boundary.
Twelve model families, one rulebook
Every candidate receives the same 44 inputs and the same folds: recency-weighted Ridge, Elastic Net, robust Huber SGD, linear and RBF SVR, distance-weighted KNN, Random Forest, Extra Trees, AdaBoost, Gradient Boosting, Histogram Gradient Boosting and a four-layer MLP, alongside zero-return and training-median baselines. The family with the lowest pooled validation MAE is frozen, then its walk-forward refit cadence (every 5, 20, 60 or 252 days, or never) is tuned on the same folds.
- Lags use shift(k ≥ 1); rolling windows use returns up to day t only
- Imputation and scaling fitted inside each training fold
- Monthly / annual indicators lagged by their publication delay
- Future-window and administrative flags never used as inputs
- Family, settings and cadence frozen before the single test run
How accurate were the forecasts?
Short-horizon oil returns are notoriously hard to predict, so the fair yardstick is a no-change (zero-return) forecast, which is what an efficient market implies. The test period includes the 2020 COVID crash, the 2022 Ukraine shock and the 2023–2025 Middle East escalation.
Forecast vs realised 5-day Brent return
bars: realised return · gold line: forecast · teal band: 90% volatility-scaled prediction band (hover for values)
Simulated price path: forecast vs actual Brent
each point turns a forecast made at the origin into a price, Pt·(1 + ŷ), and compares it with the price actually reached 5-day later. Most of the close fit comes from prices moving little relative to their level; the skill numbers above measure what the model adds.
Forecast vs outcome
every test day; dots in the shaded quadrants called the direction correctly · dashed: perfect forecast
Validation leaderboard
best configuration of each family vs the zero-return forecast · gold: selected model
| Experiment | Selected model | Test MAE | No-change MAE | Skill vs no-change | Skill vs persistence | Direction | R² |
|---|---|---|---|---|---|---|---|
| All rows · 1-day | Ridge, refit 5 | 1.625 | 1.641 | +1.0% | +27.7% | 46.6% | 0.023 |
| Eligible · 1-day | Extra Trees, refit 20 | 1.870 | 1.922 | +2.7% | +29.7% | 52.0% | 0.031 |
| All rows · 5-day | Ridge, refit 5 | 4.143 | 4.278 | +3.2% | +18.4% | 51.2% | 0.069 |
| Eligible · 5-day | Ridge, refit 20 | 4.868 | 5.058 | +3.7% | +16.1% | 57.6% | 0.054 |
MAE in percentage points of return. “Persistence” repeats the most recently completed return over the same horizon. Direction: share of days where the forecast had the right sign.
Bootstrap tests and prediction bands
Forecast errors on neighbouring days are correlated, especially for overlapping 5-day targets, so a plain bootstrap would be overconfident. We resample 20-day blocks of the test errors 5,000 times and ask how often the model beats the no-change forecast.
| Experiment | MAE gain (pp) | 95% CI | P(gain > 0) |
|---|---|---|---|
| All rows · 1-day | 0.017 | [−0.002, 0.041] | 95.2% |
| Eligible · 1-day | 0.052 | [−0.002, 0.130] | 97.0% |
| All rows · 5-day | 0.135 | [0.016, 0.281] | 99.0% |
| Eligible · 5-day | 0.190 | [0.034, 0.378] | 99.3% |
At the 5-day horizon the gain is statistically supported: both intervals exclude zero. At one day the evidence is borderline. Comparing the two training populations on identical test days gives no decisive winner, since both paired intervals cross zero.
90% prediction bands
- All rows · 1-day
- 85.0% · ±2.7 pp
- Eligible · 1-day
- 89.8% · ±3.6 pp
- All rows · 5-day
- 84.0% · ±6.7 pp
- Eligible · 5-day
- 88.3% · ±8.9 pp
coverage on the test set · median half-width. Bands scale with recent 20-day volatility, using the 90th percentile of normalised validation errors.
What did not work
- Deep MLP
- weakest family everywhere
- Flexible boosting
- loses to zero in validation
- Best performers
- heavily shrunk Ridge
The direction is a coin toss, the risk is not
Returns behave almost like a random walk, but volatility clusters: turbulent weeks tend to follow turbulent weeks. The extension applies the same point-in-time protocol to the real EIA Brent series (1987–2026). It forecasts realised volatility over the next 5 and 22 trading days with eight models (historical mean, naive, EWMA, GARCH(1,1), HAR, log-HAR, HAR-X Ridge, gradient boosting). The choice is made on pre-2020 data and tested once on 2020–2026, a period in which Brent spot fell to $9.12 and moved up to 64% in a single day.
Realised vs forecast volatility of real Brent
white: realised volatility (% per day) · gold: validation-selected model · dashed: historical average
| Model (test 2020–2026) | MAE | R² | Skill vs historical mean | Skill vs naive |
|---|
Gold row: the model chosen on pre-2020 validation. All models are shown for transparency; none was re-chosen after seeing the test.
What we learned
- Timing discipline matters more than model choice. With every feature strictly point-in-time and a purged split, the honest edge over a no-change forecast is a few percent, not the near-perfect fits that leakage would produce.
- Simple beats complex here. Strongly regularised, recency-weighted Ridge regression was selected in three of four experiments; deep and boosted models mostly learned noise.
- Longer horizons are easier. Five-day returns carry a small but statistically supported signal; daily returns are close to a random walk.
- Risk is forecastable even when direction is not. On real Brent, a 5-day volatility model beats the historical average by 15.6% out of sample, while return forecasts stay at the no-change benchmark.
- Report uncertainty, not just a number. Block-bootstrap intervals and volatility-scaled bands (84–90% coverage for a 90% target) show how far a single forecast can be trusted.