代写 R 1.

1.
STAD70 Assignment 6 Solutions
Antithetic variables are closely related to stratification with only 2 strata, i.e. with positive & negative values for Z . Their only difference is that for antithetic variables you have the same absolute values for positive and negative variables, whereas with stratification you can have different absolute values for positive and negative variables.
a.
For what type of function f does the use of antithetic variables completely eliminate
the variability of the Monte-Carlo estimator, i.e. Var Y   1 Var Y  Y   0  AV   i i 
whereYf(Z),Yf(Z)andZ~iid N(0,1) iiiii
For the type of function you identified in part a., show that the variance of the simpleMonteCarloestimatorisnotnecessarily0,i.e.Var[Y] 1VarYi0.
2n
,
n2
SOL: The variability of the estimator will be 0 when the function f is odd, i.e. when
f (x)   f (x) . In this case the expectation we try to estimate is 0, i.e. E[ f (Z)]  0,
and the antithetic variable estimator does a perfect job for any sample size n, i.e.
YAV 1n Yi Yi 1n f(Zi)f(Zi)1n f(Zi)f(Zi)0, n ni12ni1 2 ni1 2
b.
c.
For the type of function you identified in part a., show that the variance of the stratified estimator (with 2 equiprobable strata of size n each) is also not 0 and that it is smaller than that from part b., i.e. 0  Var[YStr ]  Var[Y ] .
SOL:ThesimpleMCestimatorY 12nY hasvarianceVar[Y] 1VarYwhere ii
2n i1 2n Var[Y]Varf(Z)Ef2(Z)Ef(Z)2 Ef2(Z)0,unless f(x)0,x.
i 0
SOL: We have shown in class that the variance of the stratified estimator with m=2  2 
12 equiprobable strata, is given by Var[Y ]  E  f 2 (Z)  j , where
Str   2n  j12 
 Ef(Z)|ZA,where{A} arethetwostrata.Forourspecificcase,we j  j jj1,2
have A {Z  0}& A {Z  0}, and since the function is odd and Z is Normal, we 12
have      Var[Y ]  E  f 2 (Z)  2 . Comparing this to the result 1
1 2 Str 2n  
from part b., it is obvious that the stratified estimator has smaller variance than the simple MC estimator, and its performance is better the greater  is.
2.
A European gap option has a strike price K1 and a trigger price K2 . The trigger price determines whether or not the gap option is exercised, while the strike price determines

the amount of the payoff. For example, the European gap call option has payoff given by: ST  K1, if ST  K2 , presented in the following plots:
 0,ifSTK2
Obviously, if the strike price is equal to the trigger price then the gap option is an ordinary option. Note that gap options can result in negative payoff at expiration (so they should not really be called “options”). Moreover, gap options are different from barrier options, in that for barrier options the barrier can be reached prior to expiration, whereas for gap options only the final stock price is compared to the trigger.
a. Estimate the price of a European gap call option with S0  55, K1  50, K2  60, T  1yr, r  2%,   20% and assuming the price follows GBM. Use n  100, 000
paths and calculate the standard error of your result. Compare that to the exact
price given by the R function GapOption in the package fExoticOptions. SOL: (R code attached)
b. Repeat part a. using antithetic variables, and report the new price estimate and standard error.
SOL:
c. Repeat part a. using stratification with m  5,10, & 20 equiprobable strata, and report the new price estimate and standard error.
SOL:
d. Would you expect the variance reduction methods in part b. and c. to work better for in-the-money, at-the-money, or out-of-the-money options? Justify your answer.
SOL: Both methods will work better for in-the-money options. For Antithetic Variables, we want the payoffs for the antithetic (opposite) values of Z to be negatively correlated, which will be the case it the option is in the money. For Stratification, we want the
MC estimate
Std. error
Exact price
6.120135
0.03077973
6.129964
MC estimate
Std. error
Exact price
6.123481
0.01687359
6.129964
# strata
MC estimate
Std. error
Exact price
5
6.109260
0.013101468
6.129964
10
6.127207
0.008453591
20
6.125531
0.005893443

3.
expected payoff within each stratum to be as different as possible, which again implies we prefer deep in-the-money options.
A forward start option is an option that starts at a specified future date with an expiration date set even further in the future. For example, consider a forward start call option with start date in 1yr and expiration date in 2yrs: at t  0 you pay the option premium, and at t  1 you receive a European call option with expiration date t  2 and strike price K  S1 (this is called an at-the-money forward start call, because the strike
price is equal to the asset price at t  1, which is unknown at t  0 ).
a. Estimate the price of an at-the-money forward start European call option with
S 70,T 1, T 2yr,r2%,20%andassumingthepricefollowsGBM. 0 start exp
Use n  10, 000 paths and calculate the standard error of your result. You should use the Black-Scholes formula to explicitly calculate the value of the option at Tstart , i.e. you should generate STStart and then calculate its “payoff” as the Black-Scholes price
of a European at-the-money call option with 1 year to maturity (use BSprice function provided in Lecture 8’s R code). Compare that to the exact price given by the R function ForwardStartOption in the package fExoticOptions.
b. Repeat part a. using antithetic variables, and report the new price estimate and standard error.
c. Repeat part a. using stratification with m  10 & n  1, 000 equiprobable strata, and report the new price estimate and standard error.
d. Show that the price of the at-the-money forward call option is actually a simple linear function of S0 (Hint: use risk-neutral pricing and write the payoff of the option
at Tstart as the Black-Scholes price of an at-the-money call with maturity at Texp )
MC estimate
Std. error
Exact price
6.240082
0.01256598
6.241225
MC estimate
Std. error
6.238641
0.002474718
MC estimate
Std. error
6.238967
0.002808802
TheBlack-ScholespriceforaEuropeancallis CS0(d1)erTK(d2),where lnS K(r12)T
d  0 2 ; d  d  T . For an at-the-money ( K  S ) call, in 1T210
particular, we get
 (r12)T CS(d)erT(d)S  2
(r12)T
2 .
erT
   
  T 
By risk-neutral pricing, the price of the at-the-money forward call option becomes
0  1 2  0    T 

(tower
 rT  law)   rT 
CFWD  e exp payoff   e exp (at the money Euro call at Tstart ) | STstart   
 erTstartCKST ,TTexp Tstart 
 
start
  (r12)(T T ) (r12)(T T )  erT S  2 exp start er(Texp Tstart ) 2 exp start 

 start Tstart    T T    T T  expstart expstart
   
 erTstartSTstart S0
where in the last line we used the fact that the discounted asset price is a martingale under the risk-neutral measure.
4.
An α-quantile option is an option whose payoff is determined by the αth quantile of the underlying price from time 0 until expiration. For example, the median call option (i.e.
is the
α=50%) with strike K has payoff
TT median S   K , where median S 

t
median asset price over [0,T]. Assume that the underlying asset follows GBM with
S0  60, r  5%,   25% , and use simulation to estimate the price of median call with K 70&T 1.
a.
Perform simple Monte Carlo using path discretization with t j  j T , j  0, , m m
t
t0  t0
and m50 inordertoapproximatethecontinuous medianStt0 bythediscrete
b.
m
medianS(tj )j0 . Use n 10,000paths and report the standard error of the
estimate.
Repeat part a. using the Black-Scholes price of the European call as a control variate, and report the new price estimate and standard error.
average asset price over (0,T). There are two types of averaging: 1T
arithmeticaverage:A(0,T)T 0 S(t)dt
T
MC estimate
Std. error
1.070417
0.03518883
MC estimate
Std. error
1.055038
0.02461898
5.
An Asian option is an option whose payoff is determined by the average underlying price over some pre-set period of time, typically the time till expiration. For example, theAsiancalloptionwithstrike K haspayoff A(0,T)K ,where A(0,t) isthe
1T geometricaverage:A(0,T)exp  lnS(t)dt
T 0

If the underlying asset follows GBM, then the price of an Asian option with geometric averaging can be calculated explicitly. For Asian options with arithmetic averaging, however, we rely exclusively on numerical methods for pricing.
Assume that the underlying asset follows GBM with S0  70, r  5%,   25% , and use
simulation to estimate the price of an arithmetic Asian call with K  80 & T  1 . a. Perform simple Monte Carlo using path discretization with m  50 in order to
approximate A(0,T)  1 T S(t)dt by A(0,T)  1 m S(ti ) . Use n 10,000 paths T0 m j1
and report the standard error of the estimate. SOL: (R code attached)
b. Repeat part a. using the price of the geometric Asian call as a control variate, and report the new price estimate and standard error. For implementing the control variate, you can get the exact price of the geometric Asian option using the R functionGeometricAverageRateOption inthepackagefExoticOptions.
SOL:
c. Repeat part a. using importance sampling. Change the probability measure so that E[ST ]  K , and experiment with at least two more measure changes of your choice.
Report the new price estimates and standard errors.
Notice that the estimate is diverging from that of part b. whereas the standard error decreases! Ideally, we would expect the estimates from b. & c. to be the close. The reason why this happens is that, for arithmetic Asian options, our MC estimator is biased (remember that for path-dependent options, like the Asian, we can have biased MC estimators). Specifically, it has discretization bias from approximating the continuous integral with a discrete sum. So, even though the importance sampling technique reduces variance, it seems to increase bias. The best results, in terms of accuracy, for this Asian option problem are from part b.
MC estimate
Std. error
1.410088
0.03921968
MC estimate
Std. error
1.408552
0.002142865
change of measure s.t.
MC estimate
Std. error
E[ST ]  80
1.433851
0.02886434
E[ST ]  90
1.447550
0.02077841
E[ST ]100
1.449901
0.01835852