parallelBarrier: Price Multiple Barrier Options uUsing Monte Carlo Method and...

View source: R/parallelBarrier.R

parallelBarrierR Documentation

Price Multiple Barrier Options uUsing Monte Carlo Method and the Parallel Method

Description

parallelBarrier is a function enhancing the pricing procedure of a Down (Knock-out) Barrier Option (Call or Put has to be specified in the arguments) evaluation using the Monte Carlo method. This function does not work in windows as the function mcmapply from the parallel package is not supported by windows.

Usage

parallelBarrier(data = barrier, Option, m, numsim, InOut, nbr.cores = 3L)

Arguments

data

dataset containing the underlying parameters for the options you want to price. The default set is barrier.

Option

"Put" or "Call"

m

nbr of price change simulated

numsim

nbr of paths simulated

InOut

"In" if you want the price of a Down-In option or "Out" if you want the price od a Down-Out option.

nbr.cores

number of cores you want to allow the function to use. It's set at 3 cores (3L) per default, it can be changed.

Value

the output is a vector of the expected prices of the underlying options.


PierreNGM/RCBBarrierOptionPricing documentation built on April 19, 2022, 12:03 a.m.