Statistical Confidence Level Band for Modeling Financial Markets Uncertainty
Introduction
Uncertainty is an inherent property of financial markets due to its highly dynamic and ever-evolving nature. Therefore, forecast models of financial markets should not focus on pin-point accuracy, for it will be spurious accuracy. Rather the output should be within a statistical confidence levels band. Bands can be based on quantiles of the Probability Distribution Function of the data.
Case study: Singapore’s 6-month T-Bill and SORA (Singapore Overnight Rate Average).
The chart above shows the time series (daily yields) of Monetary Authority of Singapore (MAS) 6-month T-Bill (6MT), overlaid on the SORA. SORA has a broad positive correlation with 6MT but has daily swings of significant volatility. This is natural because SORA’s daily volatility is a feature of an unsecured overnight funding benchmark: sensitive to immediate liquidity, calendar, and cross‑currency conditions of banks and other users while 6MT yield is a forward-looking, term‑averaged price with smoother microstructure and premia, so it drifts with trends and macro signals but shows less day‑to‑day noise. Therefore, if we want to forecast the SORA yield it should be a forecast within a statistical confidence level band.
An Ensemble
of Gradient-Boosted Decision Trees would be a good model for accommodating Uncertainty.
We will use the open source LightGBM gradient-boostng algorithm.
Key ideas
• Gradient boosting: builds trees sequentially; each new tree focuses on correcting the errors of the prior trees.
• Decision trees: split the feature space into regions using rules
• LightGBM specifics: Histogram-based splits for speed.
• Leaf-wise tree growth with depth constraints for accuracy and efficiency.
• Handles missing values natively.
• Works well with many features and large datasets.
• Supports quantile loss*, so you can forecast intervals (e.g., 10th/50th/90th percentiles).
Why it’s useful for SORA forecasting
• Captures nonlinearities and interactions between drivers (e.g., lagged SORA, calendar effects, 6M T‑bill).
• Flexible: you can include engineered features (lags, rolling means/vols) and exogenous variables.
• Produces strong short‑term forecasts when you avoid data leakage and validate properly.
• Train quantile LightGBM models (e.g., quantiles 0.1, 0.5, 0.9) to get forecast bands.
What is quantile regression?
• Instead of predicting the conditional mean of y given X (like ordinary regression), quantile regression predicts a chosen conditional quantile (e.g., the 10th, 50th, or 90th percentile).
• Example: A 0.90 (90th) quantile model predicts a value such that, given today’s features, the future SORA has about a 90% chance of being at or below that number.
Why it’s useful:
• It gives you full predictive distributions (not just a point), which you can turn into uncertainty bands like [q10, q90] around the median.
• How we forecast “by quantile”
• We trained separate LightGBM models for each quantile: alpha = 0.1, 0.5, 0.9.
• At prediction time, we run the same features through each model to get q10, q50 (median), and q90 for each future date.
• The q50 is your central forecast; [q10, q90] is an 80% prediction interval.
*What is Quantile Loss
What is quantile (pinball) loss?
Quantile regression is trained with the quantile/pinball loss, which is asymmetric and depends on the target quantile q in (0,1). For true value y and prediction y_hat:
If y ≥ y_hat, the loss is q × (y − y_hat)
If y < y_hat, the loss is (1 − q) × (y_hat − y)
Therefore:
L_q(y, y_hat) = max(q × (y − y_hat), (q − 1) × (y − y_hat))
• Intuitively: For q = 0.9, under-predictions (y above y_hat) are penalized 0.9 per unit error, but over-predictions are penalized 0.1 per unit. The model learns to place its prediction high enough so that roughly 90% of realizations fall below it.
• For q = 0.5, this becomes symmetric absolute loss, so the model learns the conditional median
Chart 2: SORA Quantile Regression Forecast with Gradient-Boosted Decision Trees
PROCEDURE: FORECASTING SORA WITH ENSEMBLE OF GRADIENT BOOSTED DECISION TRESS
Data Preparation & Exploration
• Load raw data (SORA and 6M T-bill from Excel)
• Clean and align time series (handle missing values, ensure consistent dates)
• Perform basic exploratory data analysis (summary stats, visualizations)
Stationarity Testing
• Run Augmented Dickey-Fuller (ADF) test on SORA levels
• Interpret p-value to determine if series has unit root (non-stationary)
• Decide on differencing strategy if needed
Feature Engineering
• Create lagged SORA values (lag 1, 2, 5, 10, 20)
• Calculate rolling statistics (5, 10, 20-day means and standard deviations)
• Compute first differences/changes (SORA_chg, TBILL_chg)
• Add calendar features (day of week, month, month-end, quarter-end indicators)
• Include exogenous variables (6M T-bill yield)
• Ensure all features are numeric and handle any remaining missing values
Model Selection & Setup
• Choose LightGBM for gradient boosting with quantile regression capability
• Set up multiple models for different quantiles (10th, 50th, 90th percentiles)
• Configure hyperparameters (n_estimators=500, learning_rate=0.05, num_leaves=31, etc.)
Validation Strategy
• Implement walk-forward validation to simulate real-time forecasting
• Split data chronologically (no random splits for time series)
• Compare against naive baseline (last-value-carried-forward)
• Evaluate using appropriate metrics (MAE, RMSE for point forecasts)
Model Training
• Train separate quantile regression models for each percentile
• Use quantile (pinball) loss function with appropriate alpha values
• Fit models on training windows with proper time series cross-validation
Forecast Generation
• Generate recursive multi-step forecasts (60 business days ahead)
• Update lagged and rolling features dynamically during forecasting
• Produce uncertainty bands using quantile predictions
• Create visualizations showing historical data + forecast with confidence intervals
Results Interpretation
• Acknowledge model limitations vs. simple baselines
• Focus on uncertainty quantification rather than point accuracy
• Present forecasts as ranges with appropriate caveats about inherent uncertainty
ADDENDA
In our case study chart above, note that the Forecast Median (Green line) sits at the bottom of the 80% Confidence Band (Shaded light green area),
What that means
The interval is wider above the median than below it:
d_lower = q50 − q10 (smaller)
d_upper = q90 − q50 (larger)
Interpretation: the model assigns more probability mass to larger upside moves than to equally large downside moves. In other words, upside risk/uncertainty is greater. Statistically, that’s a right-skewed predictive distribution.
Practical implications
Risk management: expect larger potential upside surprises than downside ones; plan hedges/limits accordingly.
Decision-making: if you’re budgeting or setting thresholds, allow more room on the upside.
How to calculate the risk asymmetry ratio r
r measures where the median (q50) sits within the forecast interval [q10, q90]. It compares how much room there is above the median vs below it.
d_lower = q50 − q10
d_upper = q90 − q50
r = d_upper / max(d_lower, ε)
Where ε is a tiny number (e.g., 1e-6) to avoid divide-by-zero if q50 ≈ q10.
r > 1 means more upside room than downside (right-skew). r < 1 means more downside room than upside (left-skew).
Concrete examples
Example A (right-skew/upside risk)
q10 = 1.20, q50 = 1.25, q90 = 1.40
d_lower = 1.25 − 1.20 = 0.05
d_upper = 1.40 − 1.25 = 0.15
r = 0.15 / 0.05 = 3.0 → r > 1.5 flag upside risk
Example B (left-skew/downside risk)
q10 = 1.10, q50 = 1.20, q90 = 1.25
d_lower = 1.20 − 1.10 = 0.10
d_upper = 1.25 − 1.20 = 0.05
r = 0.05 / 0.10 = 0.5 → r < 0.67 flag downside risk



Comments
Post a Comment