Warning: foreach() argument must be of type array|object, bool given in /var/www/html/web/app/themes/studypress-core-theme/template-parts/header/mobile-offcanvas.php on line 20

Compute with option prices in finance. In this exercise we are going to consider the pricing of so-called Asian options. An Asian option is a financial contract where the owner earns money when certain market conditions are satisfied. The contract is specified by a strike price \(K\) and a maturity time \(T .\) It is written on the average price of the underlying stock, and if this average is bigger than the strike \(K\), the owner of the option will earn the difference. If, on the other hand, the average becomes less, the owner recieves nothing, and the option matures in the value zero. The average is calculated from the last trading price of the stock for each day. From the theory of options in finance, the price of the Asian option will be the expected present value of the payoff. We assume the stock price dynamics given as, $$ S(t+1)=(1+r) S(t)+\sigma S(t) \epsilon(t) $$ where \(r\) is the interest-rate, and \(\sigma\) is the volatility of the stock price. The time \(t\) is supposed to be measured in days, \(t=0,1,2, \ldots\), while \(\epsilon(t)\) are independent identically distributed normal random variables with mean zero and unit standard deviation. To find the option price, we must calculate the expectation $$ p=(1+r)^{-T} \mathrm{E}\left[\max \left(\frac{1}{T} \sum_{t=1}^{T} S(t)-K, 0\right)\right] $$ The price is thus given as the expected discounted payoff. We will use Monte Carlo simulations to estimate the expectation. Typically, \(r\) and \(\sigma\) can be set to \(r=0.0002\) and \(\sigma=0.015 .\) Assume further \(S(0)=100\) a) Make a function that simulates a path of \(S(t)\), that is, the function computes \(S(t)\) for \(t=1, \ldots, T\) for a given \(T\) based on the recursive definition in (8.17). The function should return the path as an array. b) Create a function that finds the average of \(S(t)\) from \(t=1\) to \(t=T\). Make another function that calculates the price of the Asian option based on \(N\) simulated averages. You may choose \(T=100\) days and \(K=102\) c) Plot the price \(p\) as a function of \(N\). You may start with \(N=1000\). d) Plot the error in the price estimation as a function \(N\) (assume that the \(p\) value corresponding to the largest \(N\) value is the "right"price). Try to fit a curve of the form \(c / \sqrt{N}\) for some \(c\) to this error plot. The purpose is to show that the error is reduced as \(1 / \sqrt{N}\). Name of program file: option_price.py. If you wonder where the values for \(r\) and \(\sigma\) come from, you will find the explanation in the following. A reasonable level for the yearly interest- rate is around \(5 \%\), which corresponds to a daily rate \(0.05 / 250=0.0002 .\) The number 250 is chosen because a stock exchange is on average open this amount of days for trading. The value for \(\sigma\) is calculated as the volatility of the stock price, corresponding to the standard deviation of the daily returns of the stock defined as \((S(t+1)-S(t)) / S(t)\). "Normally", the volatility is around \(1.5 \%\) a day. Finally, there are theoretical reasons why we assume that the stock price dynamics is driven by \(r\), meaning that we consider the riskneutral dynamics of the stock price when pricing options. There is an exciting theory explaining the appearance of \(r\) in the dynamics of the stock price. If we want to simulate a stock price dynamics mimicing what we see in the market, \(r\) in Equation \((8.17)\) must be substituted with \(\mu\), the expected return of the stock. Usually, \(\mu\) is higher than \(r \cdot \diamond\)

Short Answer

Expert verified
Estimate the Asian option price using Monte Carlo simulations and plot how price and error change with the number of simulations.

Step by step solution

01

Simulate Stock Price Path

To simulate the stock price path, we will create a function that takes parameters for the number of days \(T\), initial stock price \(S(0)\), interest rate \(r\), and volatility \(\sigma\). The function will iterate for each day \(t\) from 1 to \(T\) and calculate \(S(t)\) using the recursive formula: \[ S(t+1) = (1+r) S(t) + \sigma S(t) \epsilon(t) \] where \(\epsilon(t)\) is a randomly generated normal variable with mean 0 and standard deviation 1. The function returns an array of stock prices.
02

Calculate Average Stock Price

Create a function to compute the average stock price over the period from \(t=1\) to \(t=T\). Given an array of stock prices, this function calculates the average: \[ \text{Average} = \frac{1}{T} \sum_{t=1}^{T} S(t) \] The function returns this average value.
03

Estimate Asian Option Price

Develop another function to calculate the option price using Monte Carlo simulations. It should simulate \(N\) paths of the stock price, calculate the average price for each path, and then compute the payoff for the option \[ \max \left(\frac{1}{T} \sum_{t=1}^{T} S(t) - K, 0\right) \] The function computes the expected payoff and applies discounting using \[ p = (1+r)^{-T} \times \text{average payoff} \] Return the estimated option price.
04

Price as a Function of Simulations

Use the function from Step 3 to estimate and plot the option price \(p\) against various values of \(N\) (e.g., \(N = 1000, 2000, \ldots\)). This reveals how the price estimate stabilizes as more simulations are conducted.
05

Error Analysis and Curve Fitting

Calculate the error in price estimation for increasing values of \(N\). Assume that the price computed with the largest \(N\) is the true value. Plot these errors and fit the curve \(c / \sqrt{N}\) to the error plot. This analysis validates how the error decreases approximately as \(1 / \sqrt{N}\), ensuring reliability as simulations increase.

Unlock Step-by-Step Solutions & Ace Your Exams!

  • Full Textbook Solutions

    Get detailed explanations and key concepts

  • Unlimited Al creation

    Al flashcards, explanations, exams and more...

  • Ads-free access

    To over 500 millions flashcards

  • Money-back guarantee

    We refund you if you fail your exam.

Over 30 million students worldwide already upgrade their learning with Vaia!

Key Concepts

These are the key concepts you need to understand to accurately answer the question.

Monte Carlo simulations
Monte Carlo simulations are a forecasting technique used in various fields, including finance, to approximate the probability of different outcomes. This method involves simulating random variables to compute the possible outcomes of a model or a system. In the context of Asian options, Monte Carlo simulations allow us to estimate the expected present value by generating numerous potential outcomes of stock price paths.

- **Random Sampling**: The core of a Monte Carlo simulation is its reliance on random sampling of input variables. For Asian options, this involves simulating paths of stock prices using random values for the variable \( \epsilon(t) \), which follow a normal distribution.
- **Repetitive Process**: By repeating the process thousands of times, we can see a distribution of potential payoffs. Each repetition calculates a possible path for the stock price over the option's life, allowing us to assess various scenarios of price movements.
- **Accuracy**: As we increase the number of simulations \( N \), the accuracy of our estimation improves. The larger the sample size, the more reliable the simulation results become, which is due to the law of large numbers.
Stock price dynamics
Stock price dynamics describe the movement and fluctuation of stock prices over time. In financial mathematics, this dynamic is often modeled using stochastic processes. For Asian options, the price dynamics are given by a specific equation: \[ S(t+1) = (1 + r) S(t) + \sigma S(t) \epsilon(t) \]This formula considers:
- **Interest rate \( r \)**: Represents the daily risk-free rate, affecting how prices evolve over time by growing at this expected rate.
- **Volatility \( \sigma \)**: Measures the rate at which stock prices fluctuate, adding randomness to the stock price changes.
- **Random shocks \( \epsilon(t) \)**: Modeled as standard normal random variables, introduce unpredictability into stock movements.

These dynamics help us replicate real-world price movements in a simulated environment, essential for evaluating the expected payoff of Asian options.
Expected present value
The expected present value (EPV) is a fundamental concept in finance used to determine the value of an uncertain future cash flow in today's terms. For Asian options, the EPV is calculated to assess the expected payoff of the option, discounted back to the present. \[ p = (1 + r)^{-T} \times \text{average payoff} \]This formula includes:
- **Discounting factor \( (1 + r)^{-T} \)**: Reflects the time value of money, implying that a dollar today is worth more than a dollar tomorrow. In the context of Asian options, we discount the average payoff back to its present value.
- **Average Payoff**: Represents the calculated average outcome of the option's price over numerous simulated paths. This average helps us gauge what the payoff would be under various potential market conditions.

Understanding EPV helps in making decisions regarding the option's worth and its viability as an investment.
Financial mathematics
Financial mathematics involves the mathematical tools and models used to solve problems in finance, like valuing securities, analyzing risk, and optimizing investment strategies. It is a blend of mathematical theory, statistical methods, and economic principles. In the case of Asian options, financial mathematics helps in understanding and implementing the following concepts:
- **Stochastic Processes**: These are used to model the random changes in stock prices. For example, Asian options consider daily price variations based on a stochastic differential equation.
- **Risk-Neutral Valuation**: A concept where securities are evaluated assuming a risk-free rate of return. This simplifies the pricing of options by neutralizing risk preferences.
- **Volatility Modeling**: Using historical data to estimate future price fluctuations ensures accurate pricing estimates for options.

Employing these mathematical foundations allows traders and financial analysts to effectively evaluate financial derivatives and make informed investment decisions.

One App. One Place for Learning.

All the tools & learning materials you need for study success - in one app.

Get started for free

Most popular questions from this chapter

Draw balls from a hat. Suppose there are 40 balls in a hat, of which 10 are red, 10 are blue, 10 are yellow, and 10 are purple. What is the prohahility of getting two blue and two purple balls when drawing 10 balls at random from the hat? Name of program file: 4 balls_from10.py.

Throw dice and compute a small probability. Compute the probability of getting 6 eyes on all dice when rolling 7 dice. Since you need a large number of experiments in this case (see the first paragraph of Chapter 8.3), you can save quite some simulation time by using a vectorized implementation. Name of program file: roll_7dice.py.

Guess beer brands. You are presented \(n\) glasses of beer, each containing a different brand. You are informed that there are \(m \geq n\) possible brands in total, and the names of all brands are given. For each glass, you can pay \(p\) euros to taste the beer, and if you guess the right brand, you get \(q \geq p\) euros back. Suppose you have done this before and experienced that you typically manage to guess the right brand \(T\) times out of 100 , so that your probability of guessing the right brand is \(b=T / 100\). Make a function simulate \((m, n, p, q, b)\) for simulating the beer tasting process. Let the function return the amount of money earned and how many correct guesses \((\leq n)\) you made. Call simulate a large number of times and compute the average earnings and the probability of getting full score in the case \(m=n=4, p=3, q=6\), and \(b=1 / m\) (i.e., four glasses with four brands, completely random guessing, and a payback of twice as much as the cost). How much more can you earn from this game if your ability to guess the right brand is better, say \(b=1 / 2 ?\) Name of program file: simulate_beer_tasting.py.

\(1 D\) random walk until a point is hit. Set \(\mathrm{np}=1\) in the walk1Dv.py program and modify the program to measure how many steps it takes for one particle to reach a given point \(x=x_{p}\). Give \(x_{p}\) on the command line. Report results for \(x_{p}=\) \(5,50,5000,50000\). Name of program file: walk1Dv_hit_point.py.

Simulate stock prices. A common mathematical model for the evolution of stock prices can be formulated as a difference equation $$ x_{n}=x_{n-1}+\Delta t \mu x_{n-1}+\sigma x_{n-1} \sqrt{\Delta t} r_{n-1} $$ where \(x_{n}\) is the stock price at time \(t_{n}, \Delta t\) is the time interval between two time levels \(\left(\Delta t=t_{n}-t_{n-1}\right), \mu\) is the growth rate of the stock price, \(\sigma\) is the volatility of the stock price, and \(r_{0}, \ldots, r_{n-1}\) are normally distributed random numbers with mean zero and unit standard deviation. An initial stock price \(x_{0}\) must be prescribed together with the input data \(\mu, \sigma\), and \(\Delta t\). We can make a remark that Equation (8.16) is a Forward Euler discretization of a stochastic differential equation for \(x(t)\) $$ \frac{d x}{d t}=\mu x+\sigma N(t) $$ where \(N(t)\) is a so-called white noise random time series signal. Such equations play a central role in modeling of stock prices. Make \(R\) realizations of \((8.16)\) for \(n=0, \ldots, N\) for \(N=5000\) steps over a time period of \(T=180\) days with a step size \(\Delta t=T / N\). Name of program file: stock_prices.py.

See all solutions

Recommended explanations on Computer Science Textbooks

View all explanations

What do you think about this solution?

We value your feedback to improve our textbook solutions.

Study anywhere. Anytime. Across all devices.

Sign-up for free