This assignment is an extra credit opportunity worth 10 points. The goal is to demonstrate your understanding of the topic in the different areas of problem statement through a flowchart diagram propely marked, the analytics through a clear representation of the mathematical equations, the coding through the clear and properly commented execution steps, and finally results evaluation through the assessment of quality and integrity.
The topic of interest is the pricing of an Asian option. Asian options are a form of exotic options unlike the more vanilla European options. The case considered here is a special type of Asian options where the payoff is given by the average price of the underline asset over some predetermined period until expiration time. Other variations of Asian options (outside our scope) are possible and left for the reader’s investigation. The case in point is described on p.169 . Note that Asian options are characterized as path dependent options. By this we mean that the payoff of the option is dependent on the intermediate values of the underline asset along the path. In contrast a European option is path independent because the payoff depends only on the final value of the underline asset, and not on the intermediate or historical values. The case of American options is slightly tricky. Because of the early exercise opportunity one may be inclined to view American options as path dependendent. However at any exercise point the payoff is only dependent on the current asset price and not historical. As such it is not really path dependent.
Remember to always set your working directory to the source file location. Go to ‘Session’, scroll down to ‘Set Working Directory’, and click ‘To Source File Location’. Read carefully the below and follow the instructions to complete the tasks and answer any questions. Submit your work to RPubs as detailed in previous notes.
Always read carefully the instructions on Sakai. For clarity, tasks/questions to be completed/answered are highlighted in red color (visible in preview) and numbered according to their particular placement in the task section. Quite often you will need to add your own code chunk.
Execute all code chunks, preview, publish, and submit link on Sakai follwoing the naming convention. Make sure to add comments to your code where appropriate. Use own language!
Any sign of plagiarism, will result in dissmissal of work!
#Install package quantmod
if(!require("quantmod",quietly = TRUE))
install.packages("quantmod",dependencies = TRUE, repos = "https://cloud.r-project.org")
Inspired by the flowchart diagram of the MC simulation for European option, create an equivalent flowchart diagram for the considered case of Asian option. Describe the variables, label clearly, and write the discrete mathematical representation to be coded later. You can create the flowchart using a separate tool and include an image capture here. A hand drawn image is acceptable only if well executed.
### Question 2: MC Simulation (2pts)
Implement the R-code for the MC simulation to price an Asian Call option with input characteristics similar to the European Call option considered in Lab 6, task 2B.
#this code is for Call Option
sum1=0
sum2=0
type="c"
S = 155
K = 140
t=0.5
rf=0.025
r=0.025
sigma=0.23
n=100
dt=t/100
m=1000
for(i in 1:1000){
S=155
sum1=0
for (j in 1:100) {
E=rnorm(1,mean=0,sd=1)
S=S+r*S*dt+sigma*S*sqrt(dt)*E
payoff=max(S-K,0)
sum1=sum1+payoff
}
sum2=sum2+sum1/100
}
Optionvalue=sum2/1000*exp(-rf*t)
Optionvalue
[1] 17.2593
#This code is for Put Option
sum1=0
sum2=0
type="p"
S = 142
K = 140
t=0.5
rf=0.025
r=0.025
sigma=0.23
n=100
dt=t/100
m=1000
for(i in 1:1000){
sum1=0
S=142
for (j in 1:100) {
E=rnorm(1,mean=0,sd=1)
S=S+r*S*dt+sigma*S*sqrt(dt)*E
payoff=max(K-S,0)
sum1=sum1+payoff
}
sum2=sum2+sum1/100
}
Optionvalue=sum2/1000*exp(-rf*t)
Optionvalue
[1] 4.665346
For this question the below package is needed. Follow the example at bottom of p.171 to price the same Asian Call option using instead the approximate function referenced in the example. Compare to the MC simulation.
#Install required package
if(!require("fExoticOptions",quietly = TRUE))
install.packages("fExoticOptions",dependencies = TRUE, repos = "https://cloud.r-project.org")
library("fExoticOptions")
TW=TurnbullWakemanAsianApproxOption(TypeFlag="c",S=100,SA=100,
X=100, Time=1/12, time=1/12, tau=0, r=0.1, b=0.1, sigma=0.4)
print(TW)
Title:
Turnbull Wakeman Asian Approximated Option
Call:
TurnbullWakemanAsianApproxOption(TypeFlag = "c", S = 100, SA = 100,
X = 100, Time = 1/12, time = 1/12, tau = 0, r = 0.1, b = 0.1,
sigma = 0.4)
Parameters:
Value:
TypeFlag c
S 100
SA 100
X 100
Time 0.0833333333333333
time 0.0833333333333333
tau 0
r 0.1
b 0.1
sigma 0.4
Option Price:
2.859122
Description:
Wed Feb 06 23:07:59 2019
# if we use the MC simulation R code
sum1=0
sum2=0
type="c"
S = 100
K = 100
t=1/12
rf=0.1
r=0.1
sigma=0.4
n=100
dt=t/100
m=100
for(i in 1:100){
sum1=0
S=100
for (j in 1:100) {
E=rnorm(1,mean=0,sd=1)
S=S+r*S*dt+sigma*S*sqrt(dt)*E
payoff=max(S-K,0)
sum1=sum1+payoff
}
sum2=sum2+sum1/100
}
Optionvalue=sum2/100*exp(-rf*t)
Optionvalue
[1] 3.533709
the outcome is not so close, when we follow the code in the book, the outcome of option price is fixed ,and eqials 2.859. when we use the MC simulation model with the same input , the outcomes mostly fluctuate between[3,4] ### Question 4: Greeks Calculation (2pts)
Calculating the Greeks for the Asian Option is not as straightforward using the approximate function. Instead we can approximate using numerical differentiation. Describe how would you implement a numerical differentiation to calculate the Delta. Show the code execution and the intermediate values to calculate the Delta and the Theta for the considered Asian Call option.
1.To calculate Delta
library("fExoticOptions")
TW1=TurnbullWakemanAsianApproxOption(TypeFlag="c",S=102,SA=100,
X=100, Time=1/12, time=1/12, tau=0, r=0.1, b=0.1, sigma=0.4)
TW2=TurnbullWakemanAsianApproxOption(TypeFlag="c",S=98,SA=100,
X=100, Time=1/12, time=1/12, tau=0, r=0.1, b=0.1, sigma=0.4)
print(TW1)
Title:
Turnbull Wakeman Asian Approximated Option
Call:
TurnbullWakemanAsianApproxOption(TypeFlag = "c", S = 102, SA = 100,
X = 100, Time = 1/12, time = 1/12, tau = 0, r = 0.1, b = 0.1,
sigma = 0.4)
Parameters:
Value:
TypeFlag c
S 102
SA 100
X 100
Time 0.0833333333333333
time 0.0833333333333333
tau 0
r 0.1
b 0.1
sigma 0.4
Option Price:
4.046712
Description:
Fri Feb 01 10:40:38 2019
print(TW2)
Title:
Turnbull Wakeman Asian Approximated Option
Call:
TurnbullWakemanAsianApproxOption(TypeFlag = "c", S = 98, SA = 100,
X = 100, Time = 1/12, time = 1/12, tau = 0, r = 0.1, b = 0.1,
sigma = 0.4)
Parameters:
Value:
TypeFlag c
S 98
SA 100
X 100
Time 0.0833333333333333
time 0.0833333333333333
tau 0
r 0.1
b 0.1
sigma 0.4
Option Price:
1.906738
Description:
Fri Feb 01 10:40:38 2019
Delta=(TW1-TW2)/4=0.535
2.To calculate Theta
library("fExoticOptions")
TW3=TurnbullWakemanAsianApproxOption(TypeFlag="c",S=100,SA=100,
X=100, Time=3/24, time=1/12, tau=0, r=0.1, b=0.1, sigma=0.4) #dt=1/24
TW4=TurnbullWakemanAsianApproxOption(TypeFlag="c",S=100,SA=100,
X=100, Time=1/24, time=1/12, tau=0, r=0.1, b=0.1, sigma=0.4)
print(TW3)
Title:
Turnbull Wakeman Asian Approximated Option
Call:
TurnbullWakemanAsianApproxOption(TypeFlag = "c", S = 100, SA = 100,
X = 100, Time = 3/24, time = 1/12, tau = 0, r = 0.1, b = 0.1,
sigma = 0.4)
Parameters:
Value:
TypeFlag c
S 100
SA 100
X 100
Time 0.125
time 0.0833333333333333
tau 0
r 0.1
b 0.1
sigma 0.4
Option Price:
1.907538
Description:
Fri Feb 01 11:15:05 2019
print(TW4)
Title:
Turnbull Wakeman Asian Approximated Option
Call:
TurnbullWakemanAsianApproxOption(TypeFlag = "c", S = 100, SA = 100,
X = 100, Time = 1/24, time = 1/12, tau = 0, r = 0.1, b = 0.1,
sigma = 0.4)
Parameters:
Value:
TypeFlag c
S 100
SA 100
X 100
Time 0.0416666666666667
time 0.0833333333333333
tau 0
r 0.1
b 0.1
sigma 0.4
Option Price:
2.856938
Description:
Fri Feb 01 11:15:05 2019
#theta=(TW3-TW4)/(1/12)=-11.39
Theta=(TW3-TW4)/(1/12)=-11.39
Explain how the price of the Asian Call option compares to the equivalent European Call option. Is it an expected behavior? What about the Delta comparison? Poorly stated insights will receive poor grade!
Since the Asian Option is a path dependent Option, so the option prices in the process will affect the results significantly.When the underlying assets keeps a upward trend, the European Option would be a better choice, because the payoff of the Asian Option will be weakened by the process while the European Option could gain a high profit. WHen the underlying assets price decline more or fluctuate significantly, the Asian Option would be a better choice ,the machanism of it could help investors gain more profit.
As for the Delta comparison,the delta I get from Question 4 is 0.535 ,when I try to calculate the delta for European Otion with the same dt=2, delta2=0.5511. The delta for European Option is slightly larger than that of Asian Option, it means the European is a little more sensitive to the change of underlying asset price , but not very significant.