In this section we would like to give a short guideline how to price
exotic options with Monte Carlo and Quasi Monte Carlo simulation
techniques within the framework described above. Furthermore we give
some indications about the limits of these techniques.
As a first step we have to define the payoff function corresponding to our option product. Within the methods defined in the quantlib finance we have to consider three different cases.
One underlying + path independent
In this case the payoff function is called by the pricing routine with
the simulated underlying value at maturity as the single argument. It
calculates the corresponding payoff and returns this value.
We have defined the payoff function for a put option with strike price
100 as an example for a one dimensional payoff function.
Several underlying + path independent
For options whose payoff depends on the underlying values of several
assets at maturity, we have to define a payoff function on the vector
of the underlying values at maturity. An example for such an option
is an exchange option that permits to swap a defined share with the best
performing share in a basket. Its payoff function is given by:
One underlying + path dependent
The third category of option types that are captured are path dependent options
on one underlying. The payoff function of these options depends on the underlying values at several
fixed time points during the lifetime of the option. Payoff functions for these contracts
are called with a vector of underlying values whose th element is the
underlying value at the time
which has to be specified in the model.
After defining the payoff function in XploRe we can start to calculate a price estimate with the help of the appropriate simulation routine. In the one dimensional case we just have to call
|
to get a price estimate and for the Monte Carlo case an empirical standard deviation with
respect to a start price of s0, a continuous risk free
interest rate of r, a volatility vola, a time to maturity of
dt years, the payoff function opt,
sample size itr and the random/low-discrepancy generator with number gen.
Table 16.1 shows the random number generators and table 16.2 the low-discrepancy generators that can be used.
An application of these routines for a Put option can be found in
XFGSOP1DPut.xpl
.
Pricing path-dependent options is only slightly more complicated. Here we have to define the vector of time points for which underlying prices have to be generated. This vector replaces the time to maturity used to price path independent options. Then we can apply one of the following methods to compute a price estimate for the path dependent option
|
with respect to the start price s0, the continuous risk free
interest rate r, the volatility vola, the time scheme times,
the payoff function opt,
sample size itr and the random/low-discrepancy generator
with number gen, as given in Tables 16.1 and 16.2.
Using the above quantlets, we calculate the price of an Asian call
option in
XFGSOP1DAsian.xpl
.
In the case of multidimensional options we have to define a start price vector and a covariance matrix instead
of a single underlying price and volatility value. Then we can call one of
the multi-dimensional simulation routines:
|
with respect to the m dimensional start price vector s0, the continuous risk free interest
rate r, the mm covariance matrix vola, the time to maturity dt, the
payoff function opt, the number of iterations itr and the generator number gen
according to the generators in Tables 16.1 and 16.2.
Both quantlets are illustrated in
XFGSOPMD.xpl
.
If in addition a dividend is paid during the time to maturity,
we can use the following two quantlets to calculate the
option prices.
|
The additional argument div is a m dimensional vector of the
continuously paid dividends.
An application of these functions for our basket option is provided
in
XFGSOPMDDiv.xpl
.
Monte Carlo based option pricing methods are not applicable for all types of payoff functions. There is one theoretical, and some practical limitations for the method. Let us look at the theoretical limitation first.
In the derivation of the probabilistic error bounds we have to assume the existence of the payoff variance with respect to the risk neutral distribution. It follows that we are no longer able to derive the presented error bounds if this variance does not exist. However for most payoff functions occurring in practice and the Black Scholes model the difference between the payoff samples and the price can be bounded from above by a polynomial function in the difference between the underlying estimate and the start price for which the integral with respect to the risk neutral density exists. Consequently the variance of these payoff functions must be finite.
Much more important than the theoretical limitations are the practical
limitations. In the first place Monte Carlo simulation relies on the
quality of the pseudo random number generator used to generate the uniformly
distributed samples. All generators used are widely
tested, but it can't be guaranteed that the samples generated for a
specific price estimation exhibit all assumed statistical properties.
It is also important to know that all generators produce the same
samples in a fixed length cycle. For example if we use the random
number generator from Park and Miller with Bays-Durham
shuffle, we will get the same samples after
method
invocations.
Another possible error source is the transformation
function which converts the uniformly distributed random numbers in
normally distributed number. The approximation to the inverse of the
normal distribution used in our case has a maximum absolute error of which is sufficiently good.
The most problematic cases for Monte Carlo based option pricing are options for which the probability of an occurrence of a strictly positive payoff is very small. Then we will get either price and variance estimates based on a few positive samples if we hit the payoff region or we get a zero payoff and variance if this improbable event does not occur. However in both cases we will get a very high relative error. More accurate results may be calculated by applying importance sampling to these options.