importance steven r. importancesamplingforoptionpricingsdunbar1/mathematicalfinance/lessons/... ·...

26
Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo Method Importance Sampling Examples Importance Sampling for Option Pricing Steven R. Dunbar January 25, 2016 1 / 26

Upload: others

Post on 22-Mar-2020

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Importance Sampling for Option Pricing

Steven R. Dunbar

January 25, 2016

1 / 26

Page 2: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Outline

1 Put Options

2 Monte Carlo Method

3 Importance Sampling

4 Examples

2 / 26

Page 3: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Put Option

A put option is the right to sell an asset at an establishedprice at a certain time.

The established price is the strike price, K. The certaintime is the exercise time T .

At the exercise time, the value of the put option is apiecewise linear, decreasing function of the asset value.

OptionIntinsicValue

Asset PriceK

VP (S, T ) = max(K − S, 0)

3 / 26

Page 4: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

What is the price?

For an asset with a random value at exercise time:What is the price to buy a put option before the exercisetime?

Six factors affect the price of a asset option:

the current asset price S;the strike price K;the time to expiration T − t where T is theexpiration time and t is the current time;the volatility of the asset price;the risk-free interest rate; and(the dividends expected during the life of theoption.)

4 / 26

Page 5: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Geometric Brownian Motion

How do asset prices vary randomly?

Approximate answer is Geometric Brownian Motion:Stock prices can be mathematically modeled with astochastic differential equation

dS(t) = rS dt+σS dW (t), S(0) = S0.

The solution of this stochastic differential equation isGeometric Brownian Motion:

S(t) = S0 exp((r − σ2

2)t+ σW (t)).

Simplest caseS(t) = eW (t).

5 / 26

Page 6: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Log-Normal Distribution

At time t Geometric Brownian Motion has a lognormalprobability density with parametersm = (ln(S0) + rt− 1

2σ2t) and s = σ

√t.

fX(x;m, s) =1√2πs

exp

(−1

2

[ln(x)−m

s

]2).

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

0 1 2 3 4x

lognormal pdf and cdf, m = 1, s = 1.5

6 / 26

Page 7: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Statistics of Log-Normal Distribution

The mean stock price at any time is

E [S(t)] = S0 exp(rt).

The variance of the stock price at any time is

Var [S(t)] = S20 exp(2rt)[exp(σ2t)− 1].

7 / 26

Page 8: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Monte Carlo Sample Mean

Assume a security price is modeled by GeometricBrownian Motion, with lognormal pdf.

Draw n (pseudo-)random numbers x1, . . . , xn from thelognormal distribution modeling the stock price S.

Approximate a put option price as the (present-value ofthe) expected value of the functiong(x) = max(K − x, 0), with the sample mean

VP (S, t) = e−r(T−t)E [g(S)] ≈ e−r(T−t)

[1

n

n∑i=1

g(xi)

]= e−r(T−t)gn.

8 / 26

Page 9: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Central Limit Theorem

The Central Limit Theorem implies that the samplemean gn is approximately normally distributed with meanE [g(S)] and variance Var [g(S)] /

√n,

gn ∼ N(E [g(S)] ,Var [g(S)]).

Recall that for the standard normal distributionP [|Z| < 1.96] ≈ 0.95

A 95% confidence interval for the estimate gn is(E [g(S)]− 1.96

√Var [g(S)]

n,E [g(S)] + 1.96

√Var [g(S)]

n

).

9 / 26

Page 10: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Estimating the Mean and Variance

A small problem with obtaining the confidence interval:The mean E [g(S)] and the variance Var [g(S)] are bothunknown.

These are respectively estimated with the sample meangn and the sample variance

s2 =1

n− 1

n∑i=1

(g(xi)− gn)2

10 / 26

Page 11: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Using Student’s t-distribution

The sample quantity

(gn − E [g(X)])

s/√n

has a probability distribution known as the Student’st-distribution, so the 95% confidence interval limits of±1.96 must be modified with the corresponding 95%confidence limits of the appropriate Student-tdistribution.

11 / 26

Page 12: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Monte Carlo Confidence Interval

The 95% level Monte Carlo confidence interval forE [g(X)](

gn − tn−1,0.975s√n, gn + tn−1,0.975

s√n

).

12 / 26

Page 13: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Example

Confidence interval estimation to calculate a simplifiedput option price for a simplified security. The simplifiedsecurity has a

risk-free interest rate r = σ2/2,a starting price S = 1,a standard deviation σ = 1.K = 1,time to expiration is T − t = 1.

VP (S, t) = e−r(T−t)∫ ∞0

max(0, K − x)P[eW (T−t) ∈ dx

]13 / 26

Page 14: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

R Program for Estimation

#+name Rexample

n <- 10000S <- 1sigma <- 1r <- sigma^2/2K <- 1Tminust <- 1x <- rlnorm(n) #Note use of default meanlog=0, sdlog=1y <- sapply(x, function(z) max(0, K - z ))t.test(exp(-r*Tminust) * y) # all simulation results

14 / 26

Page 15: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Problems with Monte Carlo

Applying Monte Carlo estimation to a random variablewith a large variance creates a confidence interval that iscorrespondingly large.

Increasing the sample size, the reduction is 1√n.

Variance reduction techniques increase the efficiency ofMonte Carlo estimation. Reduce variability with a givennumber of sample points, or for efficiency achieve thesame variability with fewer sample points.

15 / 26

Page 16: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Importance Sampling

Importance sampling is a variance reduction technique.

Some values in a simulation have more influence on theestimation than others. The probability distribution iscarefully changed to give “important” outcomes moreweight. If “important” values are emphasized by samplingmore frequently, then the estimator variance can bereduced.

The key to importance sampling is to choose a newsampling distribution that “encourages” the importantvalues.

16 / 26

Page 17: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Choosing a new PDF

Let f(x) be the density of the random variable, so we aretrying to estimate

E [g(x)] =

∫Rg(x)f(x) dx .

We will attempt to estimate E [g(x)] with respect toanother strictly positive density h(x). Then easily

E [g(x)] =

∫Rg(x)

f(x)

h(x)h(x) dx .

or equivalently, we are now trying to estimate

EY

[g(Y )f(Y )

h(Y )

]= EY [g(Y )]

where Y is a new random variable with density h(y).17 / 26

Page 18: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Reducing the variance

For variance reduction, determine a new density h(y) soVarY [g(Y )] < VarX [g(X)].

Consider

Var [g(Y )] = E[g(Y )2

]− (E [g(Y )])2

=

∫R

g2(x)f 2(x)

h(x)dx−E [g(X)]2 .

By inspection, we can see that we can makeVar [g(Y )] = 0 by choosing h(x) = g(x)f(x)/E [g(X)].This is the ultimate variance reduction.

Need E [g(X)], what we are trying to estimate!18 / 26

Page 19: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Educated Guessing

Importance sampling is equivalent to achange-of-measure from P to Q with

dQdP

=f(x)

h(x)

Choosing a good importance sampling distributionrequires educated guessing. Each instance of importancesampling depends on the function and the distribution.

19 / 26

Page 20: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Trivial Parameters

Calculate confidence intervals for a Monte Carlo estimateof a European put option price, whereg(x) = max(K − x, 0) and S is distributed as aGeometric Brownian Motion.

To keep parameters simple

risk free interest rate r = σ2/2, thestandard deviation σ = 1,the strike price K = 1 andtime to expiration is 1

20 / 26

Page 21: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

The quantity to estimate

∫ ∞0

max(0, 1− x)P[eW ∈ dx]

=

∫ ∞0

max(0, 1− x)1√

2πσx√T

exp

(− ln(x)2

2T

)dx .

21 / 26

Page 22: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

First Change of variable

Want ∫ ∞0

max(0, 1− x)P[eW (1) ∈ dx].

After a first change of variable the integral is

E [g(S)] =

∫ 0

−∞(1− ex)

e−x2/2

√2π

dx

22 / 26

Page 23: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Another Change of variable

x = −√y for x < 0. Then dx = dy2√yand the

expectation integral becomes∫ ∞0

1− e−√y

√2π√y

e−y/2

2dy .

23 / 26

Page 24: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Comparative results

n putestimate confintleft confintrightB-S 0.14461MC 100 0.15808 0.12060 0.19555MC 1000 0.15391 0.14252 0.16531MC 10000 0.14519 0.14167 0.14871Norm 100 0.13626 0.099759 0.17276Norm 1000 0.14461 0.133351 0.15587Norm 10000 0.14234 0.138798 0.14588Exp 100 0.14388 0.13614 0.15163Exp 1000 0.14410 0.14189 0.14631Exp 10000 0.14461 0.14392 0.14530

24 / 26

Page 25: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

A real example

Put option on S & P 500, SPX131019P01575000

S = 1614.96

r = 0.8% (estimated, comparable to 3 year and 5year T-bill rate)σ = 18.27% (implied volatility)T − t = 110/365 (07/01/2013 to 10/19/2013)K = 1575

n = 10,000

Quoted Price: $44.20

25 / 26

Page 26: Importance Steven R. ImportanceSamplingforOptionPricingsdunbar1/MathematicalFinance/Lessons/... · Importance Sampling for Option Pricing Steven R. Dunbar Put Options Monte Carlo

ImportanceSampling for

Option Pricing

Steven R.Dunbar

Put Options

Monte CarloMethod

ImportanceSampling

Examples

Results

Method Value Confidence IntervalBlack-Scholes 44.21273MonteCarlo 45.30217 (43.84440, 46.75994)Importance Sample 44.13482 (43.91919, 44.35045 )

26 / 26