SCM

Forum: open-discussion

Monitor Forum | Start New Thread Start New Thread
NIG process using the montecarlo method [ Reply ]
By: giuseppe di bernardo on 2013-04-20 08:23
[forum:39600]
Hello I'm a new member of this forum.I am working on the final dissertation of the Msc in finance. My work concerns Levy processes.
In particular I would like to price European option on the based of the Variance gamma process, the Normal Inverse Gaussian and the Meixner process through the Fast fourier transformation and the montecarlo method.
My code for pricing using the the Variance Gamma works very well, the problem is the NIG process(the second process mentioned above).
Attached there is the code o both the VG and NIG the problem with code of the NIG is may the distribution in Montecarlo method which I will write below.
I will attached the paper but look first at page 18. In any case the relevant pages are between page13 and 19.

Code of NIG through Montecarlo:
require(fImport)
data <- yahooSeries("AMZN", from="2013-01-15", to="2013-04-15")
S <- data[, "AMZN.Close"]
X <- returns(S)

S0 <- 142.2
K <- 120
T <- 61
alpha2 <- 0.2
beta <-0.5
delta <- 1.2
alpha <-3.2
r <- 0.003
d <- 0.002
m <- 0.01

# Montecarlo
n<- 50000
t <- rinvgauss(n,shape=delta*sqrt(alpha2^2-beta^2)), scale=delta)
N <- rnorm(n,0,1)
X <- beta*delta^2*t+N*delta*sqrt(t)
omega <- delta*(sqrt(alpha2^2-(beta+1)^2-sqrt(alpha2^2-beta^2))
S <- S0*exp(m*T+omega*T+X)
payoff <- sapply(S, function (x)max(x-K,0))
mean(payoff)*exp(-r*T)

Could somebody help me please?
Best regards

Thanks to:
Vienna University of Economics and Business Powered By FusionForge