Financial markets are one of the cleaner places to see stochastic processes escape the textbook. Prices move every day, but the uncertainty behind those moves is not all coming from one source. Some risk is market-wide, some is sector-specific, and some arrives as an external shock that does not politely wait for the model.
In this post, I build a three-variable volatility model around that idea. The variables are aggregate market returns, conditional sector volatility, and independent exogenous shocks. The goal is not to pretend this captures every feature of real markets, but to show how a carefully specified dependence structure gives us useful mathematics: joint density factorization, covariance structure, Monte Carlo diagnostics, and risk measures anchored to S&P 500 data.
Section 1: Mathematical Foundations - Geometric Brownian Motion
1.1 The GBM Stochastic Differential Equation
The starting point is geometric Brownian motion (GBM), the standard baseline model for asset price dynamics. For an asset price , GBM is specified by the stochastic differential equation:
where:
- is the drift coefficient (expected return rate)
- is the volatility parameter (diffusion coefficient)
- is a standard Wiener process satisfying with independent increments
The Wiener process has the fundamental properties:
- almost surely
- for
- Increments and are independent for
1.2 Solving the SDE via Itô's Lemma
To solve this SDE, we apply Itô's lemma to . For a twice-differentiable function , Itô's lemma states:
With , we have and . Substituting:
Integrating from to :
This yields the closed-form solution:
1.3 Distribution of Log-Returns
For discrete time intervals , the log-return is:
Since , we have:
For daily returns with trading years, the daily variance is and the daily standard deviation is .
1.4 Simulation Results
The animation below shows how quickly identical assumptions can lead to different realized paths. I simulate 20 GBM paths using parameters calibrated to S&P 500 data (, annualized).
GBM Path Evolution
Animation 1: Twenty GBM paths evolving over one trading year (252 days). All paths start at with identical parameters, but independent Brownian increments make them fan out over time. The spread grows with , as predicted by the diffusion term.
The static analysis is consistent with the model's theoretical predictions:
Figure 1: Geometric Brownian Motion Foundations
Figure 1: GBM foundations. Top left: multiple price paths with the characteristic fan-out pattern. Top right: log-return distribution closely matching the theoretical . Bottom left: terminal prices with the expected lognormal right skew. Bottom right: rolling volatility fluctuating around the calibrated σ = 21.4%.
Section 2: The Three-Variable Model
GBM gives us a useful base model, but it is too compressed for the question I care about here. To separate different kinds of uncertainty, I use three random variables, each with its own distribution and dependence assumptions.
2.1 Variable 1: Market Returns
Let represent daily log-returns on the aggregate market index, here the S&P 500. Under the GBM assumptions:
Calibration to S&P 500 (2020-2024):
- Sample size: 1,256 trading days
- Estimated daily drift:
- Estimated daily volatility:
- Annualized volatility:
2.2 Variable 2: Sector Volatility (Conditional Specification)
Sector-specific volatility should not be independent of market conditions. When the market moves sharply, sector volatility often rises too. I model that dependence with a conditional log-normal specification:
Equivalently, the logarithm of sector volatility is conditionally normal:
The absolute value captures a symmetric market-magnitude effect: large market moves in either direction tend to increase sector volatility. This is related to volatility clustering, but it is not a full leverage-effect model because negative and positive returns enter with the same magnitude.
Model Parameters: These values are illustrative scenario parameters chosen to make the dependence structure visible. The market return parameters are calibrated from S&P 500 data; , , and are not separately estimated from sector data in this post.
- (baseline log-volatility)
- (sensitivity to market magnitude)
- (idiosyncratic volatility noise)
The conditional expectation is:
This creates a U-shaped relationship. is minimized when and increases as grows.
The next animation makes that conditional structure easier to see. As moves away from zero, the distribution of shifts toward higher volatility:
Conditional Distribution Sweep
Animation 2: Conditional distributions sweeping from to . Left panel: the distribution shifts rightward as increases. Right panel: the red line tracks the current on the joint density heatmap. The info bar shows the U-shaped conditional expectation.
2.3 Variable 3: Exogenous Shock (Independent)
The third variable represents events outside the day-to-day market mechanism: geopolitical disruptions, policy surprises, or sudden sector-specific news. I treat this component as structurally independent of the normal market-return and sector-volatility variables.
I model as a compound Poisson process:
where:
- counts the number of shocks (jumps) per period
- are i.i.d. jump magnitudes
- (5% daily probability of a shock)
- ,
Critical Independence Assumption:
The exogenous shock is statistically independent of both market returns and sector volatility. This is a modeling assumption, not a claim that every real-world shock is perfectly isolated. The point is to study what becomes possible when one risk source can be separated cleanly from the others.
Jump Process Evolution
Animation 3: Compound Poisson jump process over 252 trading days. Top: cumulative shock value with discrete jumps marked by red stars. Between jumps, remains constant because there is no continuous drift component. Bottom: jump counting process following Poisson(λ), with the empirical jump rate converging toward the theoretical 5%.
Section 3: Independence and Joint Distributions
The independence assumption for is where the model becomes especially useful. It gives the joint distribution a simple factorization and creates a covariance matrix with a clean separated block.
3.1 Joint Density Factorization
For random variables and , independence implies .
In our three-variable system:
The important subtlety is that only the shock variable separates. The joint density of does not factorize because sector volatility is conditional on market returns:
This partial-independence structure is common in financial modeling: one part of the system is linked internally, while another component is treated as independent.
3.2 Covariance Under Independence
Independence between and the market variables gives zero covariance:
Similarly, .
The pair is different. Because is defined conditionally on , their covariance is not forced to be zero. Using the law of total covariance:
Since (conditioning on makes fixed):
With a perfectly symmetric zero-mean return distribution, the covariance between and an even function of could vanish. In this calibrated setting, the small positive drift and finite-sample simulation produce a small positive empirical covariance. The stronger point is dependence: changes with , while remains separate.
3.3 The Block-Diagonal Covariance Matrix
The full covariance matrix exhibits block-diagonal structure:
The zeros in the third row and column are direct consequences of independence. This structure gives us:
- Factored computation: Joint probabilities decompose into products
- Risk separation: Exogenous shock exposure can be modeled as a separate risk component
- Simplified inference: Parameters can be estimated separately
3.4 Simulation Diagnostics
With 100,000 Monte Carlo simulations, we can check whether the simulated data behaves the way the assumptions say it should. These are diagnostics, not proofs: low correlation and high Spearman p-values are consistent with the simulated independence assumption for , but they do not establish independence in general.
Correlation Analysis:
| Relationship | Empirical correlation | Calibrated expectation |
|---|---|---|
| and | 0.002 | 0 |
| and | 0.001 | 0 |
| and | 0.025 |
Spearman Rank Correlation Tests:
| Relationship | p-value | Decision | |
|---|---|---|---|
| vs. | 0.002 | 0.91 | Consistent with simulated independence |
| vs. | 0.001 | 0.88 | Consistent with simulated independence |
| vs. | 0.024 | Detects modeled dependence |
Independence Diagnostics
Figure 2: Independence diagnostics. Top row: scatter plots with 2σ confidence ellipses. The pair shows the modeled dependence, while the pairs involving stay close to uncorrelated. Bottom left: correlation matrix with near-zero entries for . Bottom middle: block-diagonal covariance structure. Bottom right: Spearman p-values that are consistent with, but do not prove, the simulated independence assumption for .
The joint density also becomes visible as the Monte Carlo sample grows:
Joint Density Heatmap Build-up
Animation 4: Joint density emerging from 100 to 10,000 samples. White points show raw samples; contour colors reveal where density concentrates. The characteristic shape, with higher density near and lower , then wider spread for larger , visualizes the conditional dependence structure.
Section 4: Simulation Framework with S&P 500 Data
4.1 Data and Calibration
For calibration, I use S&P 500 (^GSPC) daily data from January 2020 to December 2024. This window is useful because it contains several distinct regimes: the COVID-19 crash, the recovery, the 2022 bear market, and the 2023-24 rally.
S&P 500 Evolution
Animation 5: Historical S&P 500 price evolution, normalized to base 100, with synchronized 20-day rolling volatility. Key events are annotated: COVID crash bottom in March 2020, 2022 bear market onset, and the 2023 rally. Volatility clusters during crises and mean-reverts during calmer periods.
Parameter Summary: Market return parameters are calibrated from S&P 500 data; the sector-volatility parameters are illustrative settings for the conditional model.
| Component | Parameter | Value | Interpretation |
|---|---|---|---|
| Market returns | 0.000474 | Daily drift | |
| Market returns | 0.013504 | Daily volatility (21.4% annualized) | |
| Sector volatility | -3.5 | Illustrative baseline | |
| Sector volatility | 15.0 | Illustrative magnitude sensitivity | |
| Sector volatility | 0.3 | Illustrative idiosyncratic noise | |
| Exogenous shocks | 0.05 | Jump intensity (5% daily) | |
| Exogenous shocks | 0.0 | Mean jump size | |
| Exogenous shocks | 0.02 | Jump volatility |
4.2 Historical Context
Historical Data
Figure 3: S&P 500 empirical data (2020-2024). Top: price evolution showing the COVID crash, recovery, and later regimes. Bottom left: return distribution with a fitted normal, including slight excess kurtosis. Bottom right: rolling 20-day volatility showing regime changes and clustering.
Section 5: Risk Assessment - VaR and Expected Shortfall
5.1 Portfolio Loss Function
To connect the model to risk measurement, define portfolio loss as:
where are exposure weights. This is a stylized loss definition rather than a universal portfolio convention: positive market returns reduce loss, the log-volatility term captures exposure to sector conditions, and the absolute shock term treats shocks in either direction as costly.
5.2 Value at Risk (VaR)
For confidence level , Value at Risk is defined as:
Because combines returns, log-volatility, absolute shocks, and arbitrary exposure weights, the reported VaR values are in model loss units. They should not be read directly as percentages or dollar losses.
Simulation Results:
| Confidence level | Value at Risk (model loss units) |
|---|---|
| 90% | 1.8750 |
| 95% | 1.9336 |
| 99% | 2.0388 |
5.3 Expected Shortfall (Conditional VaR)
Expected Shortfall looks past the threshold and measures the average loss in the tail:
Simulation Results:
| Confidence level | Expected Shortfall (model loss units) |
|---|---|
| 90% | 1.9504 |
| 95% | 1.9987 |
| 99% | 2.0918 |
Here , as expected, because ES accounts for the severity of losses beyond the VaR threshold.
5.4 Variance Decomposition
The independence structure also makes the variance decomposition readable:
Empirical Decomposition:
| Component | Contribution |
|---|---|
| Total variance | 0.02640 |
| Market () | 0.7% |
| Sector () | 98.9% |
| Exogenous () | 0.0% |
| Cross-term | 0.4% |
Under these particular weights, sector volatility dominates the loss variance. That does not mean market returns or shocks are unimportant in every portfolio; it means this exposure profile is most sensitive to the sector-volatility term.
Risk Distribution Evolution
Animation 6: Portfolio loss distribution building from 100 to 10,000 simulations. Left: histogram with VaR thresholds (90%, 95%, 99%) stabilizing. Right: VaR (red) and ES (blue) convergence, showing Monte Carlo estimation consistency.
Risk Analysis
Figure 4: Risk assessment summary. Top left: final loss distribution with VaR/ES markers. Top right: tail exceedance probability on a log scale. Bottom left: variance decomposition showing sector volatility dominance. Bottom middle: component-wise VaR contributions. Bottom right: Q-Q plot showing approximate normality with slight tail deviation.
Section 6: Extensions and Limitations
6.1 Potential Extensions
Stochastic Volatility (Heston Model): Replace fixed volatility with a mean-reverting process:
Regime Switching: Allow parameters to switch between states, such as bull and bear markets, governed by a Markov chain.
Copula-Based Dependence: Replace conditional specification with flexible copula structures for .
6.2 Limitations
- Independence assumption: True exogeneity is rare in interconnected markets
- Parameter stability: Calibrated parameters may change across regimes
- Log-normal sector volatility: May not capture all empirical features
- Jump timing: Compound Poisson assumes independent, identically distributed arrival times
Conclusion
This project started as a way to make the independence assumption concrete. Instead of saying "some shocks are independent" in words, the model makes that claim visible in the joint density, covariance matrix, and simulation output.
Key Technical Contributions:
-
Joint density factorization: Independence of enables , simplifying both analytical derivations and computational implementation.
-
Block-diagonal covariance: Zero covariances involving support clean risk decomposition and separate treatment of exogenous shock exposure.
-
Simulation diagnostics: 100,000 Monte Carlo simulations produce diagnostics consistent with the simulated independence setup for (correlations ≈ 0, Spearman p-values > 0.05) and the modeled dependence between and .
-
Risk decomposition: Variance attribution shows that sector volatility dominates portfolio risk under the chosen weights, with exogenous shocks contributing marginally.
-
Calibration to real data: S&P 500 data (2020-2024) provides empirical grounding with annualized volatility σ ≈ 21.4%, consistent with post-COVID market regimes.
Combining GBM dynamics, conditional distributions, compound Poisson shocks, and explicit independence assumptions gives a framework that is analytically tractable and empirically grounded. For practitioners, the independence assumption should always be tested against the use case. For researchers, stochastic volatility, regime switching, and richer dependence models are natural next steps.
The central insight is simple but powerful: different sources of market risk interact in structured ways. Knowing which risks move together, and which can be treated separately, makes risk management and portfolio construction much more precise.
References and Further Reading
- Black, F. & Scholes, M. (1973). The Pricing of Options and Corporate Liabilities. Journal of Political Economy.
- Heston, S.L. (1993). A Closed-Form Solution for Options with Stochastic Volatility. Review of Financial Studies.
- Merton, R.C. (1976). Option Pricing When Underlying Stock Returns Are Discontinuous. Journal of Financial Economics.
- Cont, R. (2001). Empirical Properties of Asset Returns: Stylized Facts and Statistical Issues. Quantitative Finance.
Prepared for CSI 5138: Stochastic Processes
Visualizations are generated from Monte Carlo simulations using S&P 500-calibrated market parameters and illustrative sector/shock assumptions
