Monte Carlo Simulations in Portfolio Optimization

The covariance matrix of security returns can be close to singular, leading to large standard errors in expected returns. To address this, it may be necessary to factorize the returns into more generic components. The approach taken here aligns with those proposed by Sharpe (1991), Black and Litterman (1992), and Michaud (1998). After estimating the excess returns on five selected companies, H&M (retail), Saab (defense), Sandvik (industrial), Handelsbanken, and Swedbank (banking), the procedure proceeds as follows:

Data Collection and Methodology

The data for this report comprises daily closing prices and dividends spanning 2010–2025, collected from the Eikon Database, which were used to calculate log-returns. Additionally, annualized 3-month T-bill data from 2009–2025 were obtained from Sveriges Riksbank, with linear interpolation applied to estimate the missing daily rates. Using data from both sources, annualized excess returns were computed. The following steps were implemented in MATLAB to prepare the data for three Monte Carlo simulations (MCS), each introducing increasing levels of complexity:

I. Estimate the annualized covariance matrix—Ω.
The matrix quantifies asset-specific risk and cross-asset dependencies, directly influencing optimal portfolio weight allocations. The analysis reveals Saab AB as the highest-risk asset (variance = 0.106), driven by its cyclical defense exposure, while Svenska Handelsbanken remains the least volatile (0.059). Cross-asset dynamics show Sandvik and Swedbank with the strongest linkage (covariance = 0.043), signaling industrial-financial sector ties, whereas Handelsbanken and Swedbank (0.047) exemplify tight banking sector co-movement. Crucially, the weak covariance between Saab and H&M (0.023) suggests diversification potential, though their economic dissimilarities warrant caution. These relationships underscore that portfolios combining low-correlation stocks (e.g., H&M/Saab) may achieve superior risk-adjusted returns versus concentrated sector exposures.

II. Calculate the implied excess returns —μˆ = Ω∗w where w are the market capitalization weights of the chosen five assets relative to the index.
The implied excess returns are derived through reverse-engineering the market’s embedded return expectations based on observed weights. These returns serve as a benchmark in Black-Litterman models, reflecting market consensus. The implied excess returns (μˆ = Ω ∗ w) reveal a logically graduated risk-return spectrum across assets. Saab AB delivers the highest expected return (4.83%), commensurate with its position as the most volatile stock (0.106 variance), reflecting investor demand for risk compensation. Swedbank follows closely (4.45%), aligning with its relatively high risk profile. Moderate returns appear for Sandvik (4.29%) and H&M (4.14%), though notably H&M’s slightly lower return despite similar volatility to Sandvik suggests weaker risk- adjusted performance, a potential concern for optimization. Svenska Handelsbanken anchors the low-risk end with both the most stable returns (0.059 variance) and lowest yield (4.02%), completing a coherent pricing structure free of apparent anomalies. The weights are calculated using the following formula, where i stands for asset.

III. Triangulate of the covariance-matrix—Ω = P P ′
This section uses the Cholesky decomposition (Ω = PP′), which enables simulation of correlated normal returns, preserving the assets’ volatility and correlation structure. Without this, simulated returns would ignore co- movement, distorting portfolio analysis. The decomposition reveals H&M (0.30 diagonal) and Saab (0.32) as primary independent risk drivers, while their off-diagonal terms quantify how shocks propagate to other assets. Sandvik’s 0.125 exposure to H&M shows how industrial stocks inherit retail sector volatility, whereas Swedbank’s nonzero entries in all columns reflect its role as a risk sink for the entire portfolio. The lower-triangular structure explicitly models this hierarchy of risk transmission. These relationships ensure that the simulations (u = P e) properly capture both standalone volatility and the complex web of interdependencies between assets. The result is random samples that maintain the exact covariance structure of Ω, crucial for accurate risk assessment and portfolio optimization.


In this section, three different scenarios with moderately increased complexity and their impact on optimal weight allocation are tested.

IV. MCS of optimal portfolio weights under normally distributed returns (u = P e)
The mean-variance optimization is particularly sensitive to input parameters, especially with small samples or correlated returns, creating robustness concerns. To quantify this instability, 100 return scenarios (u = P e, where e ∼ N (0, I)) are simulated to derive optimal weights, revealing three critical insights: First, the optimizer successfully identifies fundamental asset attractiveness: Sandvik and Swedbank earn the highest allocations (0.25/0.24) by offering the best risk-return tradeoffs, while Saab’s premium return justifies its mid-range 0.18 weight despite high volatility. Second, the solution exhibits intelligent fragility. Swedbank’s extreme confidence interval (±1.42) shows mathematical sensitivity, yet Handelsbanken/Swedbank naturally stabilize portfolios through their countercyclical covariance properties. Finally, the framework exposes valuation gaps, penalizing H&M’s 0.14 weight for its inadequate return compensation relative to risk. In practical terms, while the optimizer provides valuable ordinal rankings of asset quality, its cardinal weight prescriptions require careful Bayesian adjustment or constrained implementation to mitigate estimation noise.

V. MCS of portfolio optimization with estimated covariance—(Ωˆ)
For the second scenario, the estimated Ωˆ from simulated samples (instead of using the true Ω) and re-optimizes, mimicking real-world estimation challenges. This highlights the effect of covariance estimation errors on portfo- lio stability. Three key findings emerge from running the simulation: First, the optimization consistently favors Swedbank (0.26) and Sandvik (0.23), as their superior risk-return profiles and beneficial covariance relation- ships persist despite estimation noise. However, their wide confidence intervals (Swedbank: [-0.92, 1.45]) reveal significant instability when parameters are uncertain. Second, higher-risk assets such as Saab receive reduced allocations (0.17) as their volatility (σ=0.52) and negative covariance effects outweigh their return potential. This aligns with Markowitz’s marginal risk contribution framework. Third, the negative confidence bounds for defensive assets (Handelsbanken: -0.96) demonstrate how correlation regimes can transform an asset’s role from risk reducer to hedge instrument. This instability echoes Michaud’s (1989) concerns about optimization sensitiv- ity while providing new evidence on regime-dependent asset roles. The findings suggest that while optimization correctly identifies relative asset attractiveness, the absolute weights require careful interpretation. Practical implications involve using robust covariance estimators, implementing constraints on extreme positions, and viewing weights as ordinal rankings rather than precise allocations.

VI. MCS of portfolio optimization with estimated excess return and covariance—(Ωˆ, μˆ)
For the third scenario, this section conducts portfolio optimization using estimated parameters (Ωˆ, μˆ) yield weights that diverge sharply from market capitalization, revealing fundamental tensions in mean-variance theory. Handelsbanken’s weight (0.43) doubles its market share (0.20), rewarded for defensive traits and favorable covariance, while Swedbank and Saab collapse to just 7% of market values, penalized for risk despite their size. Extreme confidence intervals (e.g., Handelsbanken: [-1.03, 1.88]) expose dangerous sensitivity to input assumptions, with allocations flipping between leveraged longs and shorts. Only Sandvik and H&M align closely with market weights, suggesting their risk-return profiles approximate equilibrium pricing. These deviations highlight how mean-variance optimization prioritizes statistical relationships over market equilibrium, a strength in theory but a source of instability in practice. The results argue for constrained implementations or Bayesian adjustments to temper extreme allocations.

Discussion of simulation results

The significant differences observed across scenarios IV, V, and VI primarily result from the compounding effects of estimation errors. In scenario IV, where we used the true covariance matrix and implied returns, the weights remained stable, representing the theoretically ideal allocations that would be achievable with perfect informa- tion. Moving to scenario V, the covariance matrix is estimated while keeping returns fixed, the introduction of covariance noise led to inflated risk estimates, which particularly penalized high-volatility assets like Saab. The most dramatic changes occurred in scenario VI when both returns and covariances were estimated, in which return estimation errors dominated the results, causing extreme shifts such as Handelsbanken’s substantial overweighting as the optimization process overfit to noisy signals. The underlying intuition behind these results is clear and important: mean-variance optimization demonstrates extreme sensitivity to its input parameters. When both expected returns and covariances must be estimated from data, the errors in these estimates com- bine and amplify, producing erratic and often unrealistic weight allocations. These findings strongly emphasize the practical necessity for implementing robustness checks, such as applying Bayesian shrinkage techniques or introducing reasonable portfolio constraints, when using mean-variance optimization in real-world applications.

Conclusion

While mean-variance optimization provides a theoretically sound framework for identifying efficient portfolios, the analysis reveals significant challenges in its practical implementation due to parameter uncertainty. The results clearly demonstrate that relying on unadjusted estimates can lead to unstable and potentially misleading portfolio allocations. Instead, it is recommended to use constrained optimization approaches or more robust implementations that account for estimation uncertainty. Future research in this area could productively explore the application of Black-Litterman adjustments or various resampling techniques as potential methods for reducing the instability inherent in traditional mean-variance optimization.

Leave a comment

Related articles