Anda di halaman 1dari 19

Spring 2003

rev 5 1
1
Monte Carlo
Simulation in EXCEL
Jim Grayson, Ph.D.
Jgrayson@aug.edu | 706.667.4532
2
Risk Analysis
We routinely use projections in our decisions (e.g.,
what will be the cost of materials, future interest rates,
future employment numbers, future demand, etc.)
There is uncertainty associated with whatever value
we may choose to use.
This uncertainty produces an element of risk in our
decision making.
Will often use the most likely (average) value for
this uncertain variable -- of course, this tells us
nothing about variability!
Source: Cliff Ragsdale, Spreadsheet Modeling and Decision Analysis
Spring 2003
rev 5 2
3
How to Analyze Risk?
Best case / Worst case analysis
easy to do
tells us nothing about distribution within range
or about probability of any particular outcome
What-If analysis -- change values of certain input variables to
observe effect on performance measure.
which values do you test? reflect randomness?
might require large number of scenarios to validly
represent underlying variability
doesnt allow us to represent the distribution of the
performance measure
Source: Cliff Ragsdale, Spreadsheet Modeling and Decision Analysis
4
Simulation
objective: describe the distribution and
characteristics of the possible values of the bottom
line performance measure given the possible values
and behavior of the independent variables.
essentially playing out many what-if scenarios,
except:
values are assigned in a non-biased way
user doesnt have to worry about it
(we are randomly generating sample values for
each uncertain input variable and then computing
the performance measure value)
Source: Cliff Ragsdale, Spreadsheet Modeling and Decision Analysis
Spring 2003
rev 5 3
5
Source: Bonini, Hausman and Bierman, Quantitative Analysis for Management, Irwin, p. 7
Decision Major variables in a decision problem are:
problem is:
Certain Uncertain
Simple Case models Decision analysis
(decision trees)
Case models Simulation
Complex Linear and integer
programming
Inventory models Simulation
Dynamic PERT models Inventory models
Queuing models
Classification of Decision Models
6
Conceptual Building Block:
One Uncertain Variable
Imagine that your
companys profit for the
next year is determined
by the twirl of the
spinner and then the
result multiplied by $1
million.
Further suppose that if
the result is less than
$200,000 you will be
laid off.
Source: Sam Savage, INSIGHT: Business Analysis Tools for Microsoft EXCEL.
Spring 2003
rev 5 4
7
Test your intuition by answering the following:
1. If you faced this situation over many, many years,
what would be your profit on average?
2. What is your likelihood of being laid off?
3. What should you tell the boss when he/she
demands a number for profit?
4. Create a bar chart showing the percentage of
times profit is likely to fall between 0 and .2, .2
and .4, etc.
Quickly Jot Answers
Source: Sam Savage, INSIGHT: Business Analysis Tools for Microsoft EXCEL.
8
0.2
0.4 0.6 0.8 1.0 0
%
Sketch
Source: Sam Savage, INSIGHT: Business Analysis Tools for Microsoft EXCEL.
Spring 2003
rev 5 5
9
Another Model -- More Questions:
Combination of Uncertain Variables
Suppose this time that profit is determined by two
spins, averaged together, and then multiplied by a
million dollars.
1. If you faced this situation over many, many years,
what would be your profit on average?
2. What is your likelihood of being laid off?
3. What should you tell the boss when he/she
demands a number for profit?
4. Create a bar chart showing the percentage of
times profit is likely to fall between 0 and .2, .2
and .4, etc.
Source: Sam Savage, INSIGHT: Business Analysis Tools for Microsoft EXCEL.
10
0.2
0.4 0.6 0.8 1.0 0
%
Sketch
Source: Sam Savage, INSIGHT: Business Analysis Tools for Microsoft EXCEL.
Spring 2003
rev 5 6
11
Representing Probability Distributions
Using native EXCEL capabilities
RNG for the discrete uniform distribution: INT(n*RAND())+a
where a = first integer of the range and n = number of distinct possible
outcomes
RNG for the continuous uniform distribution: a + (b-a)*RAND()
where the modeled random variable can assume any value between the
points a and b
RNG for the symmetric triangular distribution:
a + (b-a)*(RAND() + RAND() ) / 2
where a and b are the extreme points and ((b+a)/2) is the most likely
12
RNG for the normal distribution: =NORMINV(RAND(),m,s)
with mean m and standard deviation s
RNG for the exponential distribution: = -1/*LN(RAND())
where 1/ represents both the mean and standard deviation
Representing Probability Distributions
Using native EXCEL capabilities
Spring 2003
rev 5 7
13
14
An Example: Uncertain Profit
Note: This example adapted from Insight, Chapter 2 by Sam Savage.
A firm is introducing a product into a new market.
Imagine that as marketing manager you are trying to
estimate the profit that will result from the product
introduction. As you know, profit depends on:
Sales in units
Price per unit
Unit cost marginal cost per unit
Fixed costs overhead, etc. Known to be $30,000.
Profit = Sales *(Price-Unit Cost) Fixed Costs
Spring 2003
rev 5 8
15
Since this is a new market there are a lot of
uncertainties. Market scenarios are summarized below:
Low High
Volume Volume Average
Probability 50% 50%
Units 60,000 100,000 80,000
Price $10 $9 $8
Market Uncertainties
16
Unit Cost Uncertainties
VP of production believes the cost per unit will be
$7.50. But you have been advised that depending on
the cost of raw materials and actual production
experience, this cost might be as low as $6.00 or as
high as $9.00.
Low Most Likely High Average
$6.00 $7.50 $9.00 $7.50
Spring 2003
rev 5 9
17
The Boss: What is the profit going to be for the
new product?
You: Im not sure because I dont know what sales
or prices or costs are going to be.
The Boss: What are we paying you for? Give me a
number and I want it in 15 minutes!
Enter the Boss
18
Worksheet
=B6*(B7-B8)-B9
Great! Profit is $90,000, you have a number for the
boss and you have time to spare!
Spring 2003
rev 5 10
19
G11. =D11+(F11-D11)*(RAND()+RAND())/2
G7. =IF(RAND()>0.5,F7,E7)
G6. =IF(RAND()>0.5,F6,E6)
FORMULAS FROM RANGE G6:G11
B8. =G11
B7. =G7
B6. =G6
FORMULAS
FROM RANGE
B6:B8
Incorporating Uncertainty in Model
20
In cell D14 enter =B11
In cells C15 through C514 enter the series 1 to 500
Spring 2003
rev 5 11
21
1. Select range of cells.
2. Select Data on the main menu.
3. Click Table.
4. In the table dialog box enter any blank
cell for the Column input cell.
5. Click OK.
Run simulation using a Data Table
22
Highlight cells C14 to D514
Click on Data | Table and then in the dialog box
enter A14 (or any blank cell) in column input cell.
Then click OK.
Spring 2003
rev 5 12
23
Highlight cells D15 to D514 then Edit | Copy | Edit |
Paste Special | Values to freeze the numbers.
Now use Tools | Data Analysis | Histogram and then
Descriptive Statistics to analyze the results.
24
Histogram
0
5
10
15
20
25
30
-
1
0
6
8
6
4
-
4
3
1
0
6
2
0
6
5
1
8
4
4
0
9
1
4
8
1
6
7
2
1
1
9
2
5
2
7
5
6
8
3
M
o
r
e
Bin
F
r
e
q
u
e
n
c
y
.00%
20.00%
40.00%
60.00%
80.00%
100.00%
Frequency
Cumulative %
Spring 2003
rev 5 13
25
Summary Statistics
26
Back to the Boss
You: Well boss, if you average all the things that might
happen we actually ended up with an expected profit of
$93,442, but this is not the whole story.
Boss: What do you mean. Remember, I want a
number.
You: Well, there is a 10% chance we will lose at least
$31,000. Look at the graph and the percentiles. The
number could be between -$106,864 and +$339,440.
There is a one in five chance we will earn only about
$500 profit. But also a one in five chance of making
more than $180,000.
Spring 2003
rev 5 14
27
You: Boss, you have to decide whether to go ahead or
not with the new product.
One Year Later the product lost money
Without running simulation.
Boss: You said we would make over $90,000. Youre
fired.
With simulation:
Boss: Well, we knew the risk and decided to take the
gamble.
28
Lisa Pon has just been hired as an analyst in the corporate
planning department of Hungry Dawg Restaurants. Her first
assignment is to determine how much money the company needs
to accrue in the coming year to pay for its employees health
insurance claims. Hungry Dawg is a large, growing chain of
restaurants that specialize in traditional southern foods. The
company has become large enough that it no longer buys
insurance from a private insurance company. The company is
now self-insured, meaning that it pays health insurance claims
with its own money (although it contracts with an outside
company to handle the administrative details of processing claims
and writing checks.)
Source: Cliff Ragsdale, Spreadsheet Modeling and Decision Analysis
A Corporate Health Insurance Example
Spring 2003
rev 5 15
29
The money the company uses to pay claims comes from
two sources: employee contributions (or premiums
deducted from employees paychecks), and company
funds (the company must pay whatever costs are not
covered by employee contributions.) Each employee
covered by the health insurance plan contributes $125 per
month. However, the number of employees covered by
the plan changes from month to month as employees are
hired and fired, quit or simply add or drop health
insurance coverage. A total of 18,533 employees were
covered by the plan last month. The average monthly
health claim per covered employee was $250 last month.
Hungry Dawg Continued
30 Source: Cliff Ragsdale, Spreadsheet Modeling and Decision Analysis
Spreadsheet Model
Note Assumptions:
Spring 2003
rev 5 16
31
32
Spring 2003
rev 5 17
33
From analyzing historical data we have determined the
following:
The change in the number of covered employees from one
month to the next is expected to vary uniformly between a 3%
decrease and a 7% increase.
The average month claim per employee can be modeled as a
normally distributed random variable with a mean increase of
1% per month and a standard deviation of 3%.
Incorporating Uncertainty in the
Health Insurance Example
34
Spring 2003
rev 5 18
35
FORMULAS FROM RANGE B11:G12
G12. =E12-C12
E12. =D12*B12
D12. =RiskNormal($D$6*(1+$F$6)^A12,$H$6)
C12. =$D$7*B12
B12. =B11*RiskUniform(1-$F$5,1+$H$5)
G11. =E11-C11
E11. =D11*B11
D11. =RiskNormal($D$6*(1+$F$6)^A11,$H$6)
C11. =$D$7*B11
B11. =D5*RiskUniform(1-F5,1+H5)
36
Spring 2003
rev 5 19
37
38

Anda mungkin juga menyukai