Trading Dev AcademyFree quant education

Free lesson · Portfolio management theory

Bayesian views, forecast uncertainty and robust decisions

Open interactive lessonPractice calculationsExplore labs

Start with the idea

A forecast should be weighted by its uncertainty. Bayesian combination blends a prior view with new evidence; robust optimisation asks what remains attractive when estimates vary within a specified uncertainty set.

Symbols, units & horizon
  • m₀: prior mean estimate
  • v₀: uncertainty variance of that mean
  • m₁: independent Gaussian measurement of the same mean
  • v₁: measurement uncertainty variance
  • m_post,v_post: posterior mean and its uncertainty
  • Precision: inverse variance
  • Units: mean-return units and their square, distinct from asset return variance

When and why to use this

Use uncertainty-aware forecast combination before allocation so a noisy new model cannot dominate solely through a large point estimate.

The scalar normal-normal example gives the same intuition as larger Bayesian portfolio frameworks: precise evidence receives more weight. In a Black–Litterman-style setting, views may apply to combinations of assets rather than individual returns, and their uncertainty must be specified separately from return volatility.

Do not confuse uncertainty about the expected return with the volatility of realised returns. A volatile asset can have a precisely estimated mean in an idealised large sample, while a seemingly stable signal can have a highly uncertain expected edge after extensive selection.

Robust decisions can shrink expected returns, penalise uncertainty or optimise under explicit worst-case assumptions. These choices encode model uncertainty; they do not create information. Test their impact on turnover, concentration and realised outcomes using the same data available to the original forecast.

vpost=(1v0+1v1)−1,mpost=vpost(m0v0+m1v1)
Model assumptions, derivation and arithmetic

Bayesian views, forecast uncertainty and robust decisions

  1. Multiply two normal density kernels in the unknown mean and collect their quadratic terms. The coefficient on mean² is 1/v₀+1/v₁.
  2. The linear coefficient is m₀/v₀+m₁/v₁. Completing the square gives posterior variance as inverse total precision.
  3. Multiply that variance by the linear precision-weighted mean term to obtain the posterior mean. Independence and Gaussian uncertainty are substantive assumptions.
Work it by hand

Prior mean 2% with SD 2%, new estimate 6% with SD 4%: precisions 2500 and 625. Posterior mean=(50+37.5)/3125=.028, or 2.8%; posterior SD≈1.789%.

Apply it in a strategy

  • Separate mean-estimation uncertainty from realised return risk and document the source of each.
  • Combine or shrink forecasts using a training-only uncertainty model, accounting for dependence between sources.
  • Compare allocation stability and incremental net value with simple averaging and a frozen incumbent.

Research deliverable

Provide a forecast-combination sheet with source means, uncertainty, dependence assumptions and sensitivity to confidence choices.

Python implementation

Self-contained teaching example. Python 3.10+; dependencies and input conventions are shown in the code and notation. Run in your own Python environment.

from math import sqrt

def normal_mean_update(prior_mean,prior_variance,view_mean,view_variance):
    if min(prior_variance,view_variance)<=0: raise ValueError("Positive uncertainty variances required")
    variance=1/(1/prior_variance+1/view_variance)
    mean=variance*(prior_mean/prior_variance+view_mean/view_variance)
    return mean,variance,sqrt(variance)

print(normal_mean_update(.02,.02**2,.06,.04**2))

Continue learning

Portfolio Theory: Estimation, Risk Budgets & Rebalancing — all lessons
  1. Mean–variance theory and the efficient frontier
  2. Covariance estimation, shrinkage and fragile allocations
  3. Regime uncertainty: combine scenarios before allocating
  4. Marginal risk, risk contributions and strategy overlap
  5. Bayesian views, forecast uncertainty and robust decisions
  6. Turnover, no-trade regions and dynamic portfolio management

Quantitative finance and development glossary · Python resources and libraries · Research sources and limitations