Skip to content
All library documents

Computing Stock–Option Moments by Integrating Over Stock Prices

Article Quant Q&A · Author: Bob Jansen

Summary

The document explains how to calculate the mean and variance of an option’s value, and its covariance with the underlying stock, when the option price is a deterministic function of the stock price. Instead of simulating many paths, it integrates the option pricing function against the probability density of the future stock price. It gives formulas for the option-value mean, variance, and stock–option covariance, and suggests numerical quadrature for evaluating the integrals.

The proposed density is the Black–Scholes lognormal density, with the future stock price substituted where the strike appears in the density expression. This approach can provide the joint moments at a selected future time under the chosen model and option-pricing assumptions. The document does not report numerical results or compare the approach with simulation. Its conclusions depend on the assumed stock-price distribution and on using the pricing formula as the option’s value at each future state; it does not specify parameters or address changes in volatility, rates, or other market conditions.

Key ideas

  • When option value is a deterministic function of the stock price, their joint moments can be computed from the stock-price distribution.
  • Integrate the option pricing function against the future stock-price density to obtain the expected option value.
  • The option-value variance follows by integrating squared deviations from its mean.
  • Stock–option covariance follows by integrating the product of deviations in stock and option values.
  • Numerical quadrature is suggested as a practical way to evaluate the integrals.

Tags

Full text
# Simulating the joint dynamics of a stock and an option


# Simulating the joint dynamics of a stock and an option












I want to know the joint dynamics of a stock and it's option for a finite number of moments between now and $T$ the expiration date of the option for a number of possible paths.

Let $r_{\mathrm{s}}$ and $r_{\mathrm{o}}$ denote the return on the stock and the option. Then I'm interested in knowing $\mathrm{E}_t([r_{\mathrm{s}}; r_{\mathrm{o}}])$ the expectation of the return from $t$ to $t+1$ and $\mathrm{Var}_t(r_{\mathrm{s}}, r_{\mathrm{o}})$ the variance from $t$ to $t+1$. The expected return and volatility of the stock are known.

My first idea is to use Monte Carlo with the following pseudocode:

```
N <- number of paths
T <- number of moments
M <- number of subpaths
S <- current stock price
for i = 1 to N:
    S_0 <- S
    for t = 0 to T-1:
        for j = 1 to M:
            S_{t+1,j} = f(S_t)
            O_{t+1,j} = BSM(S_{t,j})
        S_{t+1} <- mean(S_{t+1,j})
        E_{i,j} <- mean(S_{t+1,j}, O_{t+1,j})
        V_{i,j} <- var(S_{t+1,j}, O_{t+1,j})
return (E, V)
```

where $S_t$ is the current stock price, $f(S_t)$ gives a realization of stock price at the next moment given the current stock price, let's assume geometric Brownian Motion, $\textrm{BSM}(S_t)$ gives the option price given the current stock price and some arbitrary parameters using the BSM formula and `E` and `V` the values I'm interested in.

This can probably be optimized by a number of clever ideas such as reusing the draws from the probability distribution and discretizing the state space and use a memoized BSM. This is, however, not what I'm looking for. I rather calculate the mean and variance directly, the question is: how?

## Answer by Brian B (score 8, accepted)

https://quant.stackexchange.com/a/3013

In this scenario, the "joint dynamics" are trivially computed since the option value is a known deterministic function of stock price. For example, the mean of the option value for time $\tau$ is $$ \mu_O = \int_0^\infty BSM( S_\tau ) p(S_\tau) dS_\tau $$ which is best computed using quadrature as available in standard numerical libraries like scipy. The function $p(S_\tau)$ would typically be the Black-Scholes probability density $$ \frac{n( d_2(S_0,S_\tau) )} {S_\tau \sigma \sqrt{\tau} }. $$ with $S_\tau$ taking the place of strike $K$ in the formula for $d_2()$.

Similarly, the variance of the option value for time $\tau$ is $$ \int_0^\infty (BSM( S_\tau ) - \mu_O)^2 p(S_\tau) dS_\tau $$ and covariance of option value with stock price would be $$ \int_0^\infty (BSM( S_\tau ) - \mu_O)(S_\tau-\mu_S) p(S_\tau) dS_\tau. $$

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.