Monte Carlo Simulation

It is a method used to generate multiple values when there is uncertainty in a variable. 

Adin Lykken

Reviewed by

Adin Lykken

Expertise: Consulting | Private Equity

Updated:

April 30, 2023

Monte Carlo simulation often called an MC simulation, is a statistical method applied in modeling the probability of different outcomes in a problem. It is a method used to generate multiple values when there is uncertainty in a variable. 

Monte Carlo Simulation

Often a range of values may be more useful than using a single value and generating a single output.

Ulam Stanislaw created the modern version of this simulation during World War II to assist in the Manhattan Project. This simulation was used to find a range of possible values for the distance neutrons travel during neutron diffusion. 

This simulation solved the uncertain variables and paved the way for the creation of the atomic bomb and an Allied victory. 

The model gets its name from the city of Monte Carlo in Monaco. This city has gained a reputation for casinos and gambling, indicating the simulation's incorporation of uncertainty.

Since then, it has become widely used in many applications. The simulation is used across many fields, including finance, engineering, mathematics, and the sciences. Within finance, this method has been used in many ways. For example, the simulation has been used to price options and convertible bonds, which behave similarly. 

The simulation has also been applied in portfolio management. Here it is used to estimate the value of a portfolio and create a distribution of potential future cash flows and price paths. 

Circle

The simulation is also used in the sensitivity analysis. This allows investors to supply many values to a single variable to test how it affects a financial model.

The MC simulation is very useful in finance and other applications. For example, it is used when there is uncertainty in a variable. Its main benefit is that it saves time and energy by plotting these models by randomly selecting from a distribution of values. 

It can be especially useful when there are many uncertain variables. For example, it would not be easy to calculate the various outputs from a range of inputs for these variables.

What is Monte Carlo Simulation?

It is a statistical model that builds a probability distribution of outcomes that rely on one or more uncertain variables.

The famous mathematician Stanislaw Ulam invented the modern version of this simulation. He created it in the 1940s while working on the Manhattan Project. 

The scientists had most of the information, but some uncertain variables prevented them from being able to complete the work. 

Scientists used the MC simulation to create a probability distribution of the distance traveled by a neutron during neutron diffusion. When it worked, the atom bomb was born and was forever named Monte Carlo to depict the use of the method.

Statisticians use the MC simulation in models with uncertain variables. 

Typically they supply a standard deviation and median value. Next, the simulation finds the range of possible values and, through random sampling, selects values to run through the model. 

The simulation may run thousands of times to create a distribution of samples. It can show the probability and outcome of each possible value of the uncertain variable.

This simulation is most useful when there are many uncertain variables. Plotting all of them in a probability distribution would be tedious by hand.

The simulation can be used in several scenarios and is popular in many fields. 

Finance, marketing, software development, engineering, and physics are some fields where this technique is extensively used. 

One may use this with any problem with multiple possible outcomes and varying probabilities. In finance, the MC simulation has a range of uses and is frequently practiced. 

Investors use this method to price options, forecast portfolio outcomes, and perform sensitivity analysis.

How Monte Carlo Simulation Method Work?

The Monte Carlo simulation produces a probability distribution of outcomes based on multiple random values of one or more inputs. This process involves the following steps:

  1. Find the uncertain variable or variables that may include a range of possible values.
  2. Determine the range of values and the probability of their occurrence.
  3. Use the MC simulation to select values from this range randomly. Then create a graph of outcomes from testing these randomly selected values for the same variable.

The values the Monte Carlo method randomly draws from may be an equally weighted range. In other cases, some values may be more probable than others. 

In this instance, one must supply the simulation with an equation that dictates the probability of certain values over others. Many examples include a normal distribution

This is defined by a mean (𝜇) and standard deviation (𝝈), which measures the degree of variation within a distribution.

In excel, this is graphed by the function =norm.inv(x, 𝜇, 𝝈) where

  • X = Probability
  • 𝜇 = Mean
  • 𝝈 = Standard deviation

In an MC simulation, often, the probability is defined by the rand() function in excel. This function chooses a random number at which to evaluate the probability. 

Coding

The standard deviation is the square root of the average variance of a distribution. The mean, of course, is the average of the values in the distribution. 

This equation will generate a random number selected from a normal distribution. The function can be run many times to generate various values for a single uncertain variable.

In finance, an asset's price path is often calculated using a lognormal distribution. This includes a right skew. This lognormal distribution is calculated using the probability density function. The excel formula for this is very similar to the normal distribution. 

It looks like this: =lognorm.inv(x, 𝜇, 𝝈), where

  • X = Probability
  • 𝜇 = Mean
  • 𝝈 = Standard deviation

Again, usually, the probability is selected at random, which is generated by the rand() function. This function, once again, will generate a random number within the distribution range. This only generates a single output but can be run many times to generate multiple potential values for the uncertain variable.

Excel is not the only place one can use to create a Monte Carlo simulation. Often this simulation is created through other computer programming languages such as Python. 

These platforms may be more suited for generating models such as the MC simulation. For those without coding experience, excel functions may be easier to use.

MACHINE LEARNING - PYTHON FUNDAMENTALS

Sign Up for our Machine Learning - Python Fundamentals Course

The Insider's Course on How to Leverage Your Excel Skills to Learn Python Fundamentals and Make Yourself Irreplaceable...

Learn More

Monte Carlo Simulation for valuing options

This simulation is a very commonly utilized tool for option pricing. 

Options are a type of derivative. When someone purchases an option, they are purchasing a contract that they can choose whether or not to execute, hence the name "option." 

This contract is a deal to buy 100 shares of a given security at a certain price and includes a small fee on each share. 

There are various ways that investors attempt to value options to make a profit, and some of these methods benefit from using the MC simulation. 

Specifically, Asian options are particularly suited for using this simulation. The price of an Asian option is based on the average price of the underlying asset over a specific period of time. 

This is unlike American and English options, which are priced based on the underlying asset at the time of execution.

Investors use the MC simulation to model multiple potential asset price paths. They can then calculate the would-be payoff from these price paths and discount them back to their present value. These values are then averaged to find an expected value of the option.

This method is most commonly applied to Asian options. There are, however, methods of using the Monte Carlo simulation that should yield a value for an English option.

This value should be the same as using the Black-Scholes model. 

Using constant drift in a geometric Brownian motion, the model follows this equation:

dAt = μAtdt + 𝝈AtdWt

Where:

  • A = Underlying asset price
  • t = time to maturity
  • μ = Constant drift
  • 𝝈 = Volatility
  • W = random variable

The W is where the Monte Carlo simulation can play a big role. It supplies the equation with various random samples. The random sampling of a normal distribution usually chooses these.

Although more difficult to price, American options have a pricing method that involves the MC simulation. 

The trouble with American options is that they allow for exercising the option before its maturity. A potential solution is the least squares method. 

This method is accomplished by generating future asset prices and performing a backward induction to find the asset price at every point along the asset's price path. 

At each price along the asset's price path, determine the value of exercising the option vs. the risk and potential payoff of exercising in the future. 

Lastly, discount the cash flows to their present value and average them across each price path.

The Monte Carlo simulation is also helpful for pricing convertible bonds

These are bonds that can be converted into equity before their maturity. This bond behavior may sound similar to how an American option can be exercised before maturity. 

They behave somewhat similarly, and investors can also apply the least squares method to pricing convertible bonds. 

The MC method can also be valuable when pricing options based on baskets of multiple securities. This is because this simulation can account for many variables and generate different values for all of them. 

Monte Carlo Simulation for Portfolio Management

This may also be used in portfolio management and applied in a few different ways.

This simulation can help plot risk and reward. This method can create a graph of many portfolios based on various risk allocations. These portfolios show the potential earnings of various portfolios of different models. 

High-risk portfolios have a higher standard deviation than low-risk portfolios. This means they may earn higher profits but less consistent earnings than a low-risk portfolio. 

Plotting the various values of the risk and reward and their probability can help craft a portfolio and measure expected returns.

One may also use the MC simulation to create a probability distribution of returns on a specific portfolio. 

There are many ways an investor can generate price paths for portfolios. Some equations, for example, may be the capital asset pricing model (CAPM), the Sharpe ratio, the Treynor ratio, or the Information ratio.

These can graph a series of price paths for any given portfolio. These equations are all meant to find the expected return of a portfolio, and the MC simulation can give uncertain variables multiple values.

In portfolio valuation, Monte Carlo methods are applied to scenarios with more than two possible values for each variable. For example, in 2022, the Federal Reserve will likely raise interest rates. 

This would affect portfolios heavily, although people are still determining how much interest rates will rise. The previous year, inflation had been very high, and investors are still determining what to expect in 2022. 

These are both variables that the MC simulation could be useful for because of their uncertainty. It can calculate various expected values that may be useful to look at. 

MC methods are usually computationally intensive. Using them for all combinations may be too expensive to calculate the whole probability distribution. 

For cases like this, one could generate many random samples with replacements from all possible combinations and then estimate the return or variance as an average over these samples.

Monte Carlo Simulation for financial modeling

The Monte Carlo simulation can be especially useful for sensitivity analysis.

Sensitivity analysis tests certain variables within a model to see how they affect the overall outcome. 

This is common practice in financial modeling. It helps investors get a better feel for their model and the likelihood of profitability, even if certain assumptions are slightly incorrect.

The MC simulation is well suited for this practice, as it can create a probability distribution of outcomes for uncertain variables. 

Investors supply a range of relevant values, and the simulation will take care of the rest. 

This method can also work with multiple uncertainties, making it a great asset. Modeling outcomes from multiple values for the same variable can be a tedious process, even for a single uncertain variable; when working with many, this method is a useful tool that can save time and energy. 

Check out this video from our Financial Statement Modeling Course for more information about sensitivity analysis!

Elite Modeling Package

Everything You Need To Master Financial Modeling

To Help You Thrive in the Most Prestigious Jobs on Wall Street.

Learn More

Pros and Cons of Monte Carlo Simulation

Monte Carlo simulation is a complex statistical method. It helps in modeling the probability of different outcomes in a problem. 

MC simulations have been applied to a wide variety of areas. This includes financial modeling and forecasting to software development and engineering. There are many advantages to using this technique in various applications. 

Some of them are:

  • A computer can perform a large number of trials to find out the probabilities for all possible outcomes
  • Simulation models can be created with simple formulas that require little computer programming skills
  • The technique is easy to understand and learn
  • It provides good estimates when dealing with high dimension
  • Computer models allow for easy experimentation and time savings
  • Results obtained using MC simulation may be more accurate when compared with traditional methods

The Monte Carlo simulation is a very useful tool for many subjects and is often used within finance. Despite this, there are also many disadvantages to using this method.

One of the biggest is that it is computationally intensive, which makes it time-consuming to complete, especially when a situation with many variables is considered. 

But this disadvantage can be solved by parallel computing, which can also speed up calculations.  

Financial planners find the MC simulation particularly frustrating. They claim it could be better at measuring patterns. 

Thinking

Estimating portfolio returns over many years often need help, even if the portfolio can include the average returns on a portfolio every year-the order of those returns matters for compounding returns. 

The randomness of the simulation is of little use in a market full of patterns that humans can more easily discern.

Lastly, the MC simulation is wrought with human error. This method saves time and removes the tedious process of creating the same model repeatedly for slightly different variables. 

Even so, the value of those variables still depends on the range estimated by the one running the simulation. The statistician must provide the distribution of values the simulation draws from, which can sometimes lead to erroneous results.

Free DCF Crash Course

Sign Up for our Free DCF Modeling Crash Course

Begin your journey into financial modeling with our free DCF Modeling Crash Course.

Learn More

Researched and authored by Shaun Desai

Free Resources

To continue learning and advancing your career, check out these additional helpful WSO resources: