Monte Carlo Simulation & Risk Analysis
Monte Carlo simulation is a way to represent and analyze risk and uncertainty. It was named after the Monte Carlo Casino which opened in 1863 in the Principality of Monaco on the French Riviera. Instead of a roulette wheel or a deck of cards, Monte Carlo simulation generates random numbers using a (pseudo) random number algorithm. In Monte Carlo simulation, the uncertainty in key input quantities is represented as a probability distribution.
In standard Monte Carlo simulation, a software program samples a random value from each input distribution and runs the model using those values. After repeating the process a number of times (typically 100 to 10,000), it estimates probability distributions for the uncertain outputs of the model from the random sample of output values. The larger the sample size, the more accurate the estimation of the output distributions.
The speed of Monte Carlo
A common misconception about Monte Carlo simulation is that the computational effort is combinatorial (exponential) in the number of uncertain inputs – making it impractical for large models. This is true for simple discrete probability tree (or decision tree) methods. But, in fact, the great advantage of Monte Carlo is that the computation is linear in the number of uncertain inputs – it is proportional to the number of input distributions to be sampled.
The sample size you need is controlled by the degree of precision that you want in the output distributions you care about. Suppose you are interested in estimating percentiles of a cumulative distribution, there’s no need to increase the sample size just because you have more uncertain inputs. For most models, a few hundred up to a thousand runs are sufficient. You only need a larger sample if you want high precision in your resulting distributions, and a smooth-looking density function. Given the inherent uncertainty in the inputs, higher precision is usually an aesthetic preference rather than a functional need.
How do you get the input distributions?
Sometimes you can fit a distribution to historical data based on the quantity. But often you are trying to forecast using quantities for which you have little or no historical data – or data on related quantities only.
In that case, you may ask an expert on the topic to express his or her best judgment about the quantity in the form of a probability distribution. There is a well-developed method for expert elicitation of this form. If the quantity is important, you may consult several experts and aggregate their opinions.
It’s usually best to represent these distributions using selected fractiles or the cumulative probability. If the quantity is discrete, or you find it easier to treat it as discrete, you can ask the expert for probabilities of each discrete value. Sometimes it’s fine to use a standard parametric distribution, such as a normal, lognormal, uniform, triangular, or beta distribution.
Latin hypercube sampling
Latin Hypercube Sampling (LHS) is a way of generating random samples of parameter values. It is widely used in Monte Carlo simulation because it can drastically reduce the number of runs necessary to achieve a reasonably accurate result.
LHS is based on the Latin square design, which has a single sample in each row and column. A “hypercube” is a cube with more than three dimensions; the Latin square is extended to sample from multiple dimensions and multiple hyperplanes.
LHS can lead to more accurate results (in terms of true variability) given any amount of processing time.
Monte Carlo Software
Microsoft Excel and other spreadsheets do not support Monte Carlo simulation directly. But, there are a number of software products that are add-ins to Excel that let you perform Monte Carlo simulation.
The best known are Oracle Crystal Ball and Palisade Software’s @Risk, which are both excellent products. What is different about Analytica is that Lumina designed Analytica from its inception to perform Monte Carlo simulation (and LHS methods), so, probabilistic analysis was fully integrated into the product from the start.
This gives Analytica’s Monte Carlo features certain advantages over spreadsheet add-ins, in terms of ease of use and speed of computation. You can define any variable, or any cell in an array, as a discrete or continuous distribution. You can view the probability distribution for any resulting variable as a set of probability bands (selected percentiles), as a probability density function, cumulative distribution function, or even view the underlying random sample.