Monte Carlo Simulation in Excel Jake Blanchard Spring 2010 Uncertainty Analysis for Engineers1.

Slides:



Advertisements
Similar presentations
McGraw-Hill/Irwin Copyright © 2013 by The McGraw-Hill Companies, Inc. All rights reserved. A PowerPoint Presentation Package to Accompany Applied Statistics.
Advertisements

6 - 1 Lecture 4 Analysis Using Spreadsheets. Five Categories of Spreadsheet Analysis Base-case analysis What-if analysis Breakeven analysis Optimization.
1 Using Excel for Statistics Office 2010 and 2013.
Simulation Operations -- Prof. Juran.
Session 7a. Decision Models -- Prof. Juran2 Overview Monte Carlo Simulation –Basic concepts and history Excel Tricks –RAND(), IF, Boolean Crystal Ball.
MBA7020_07.ppt/July 11, 2005/Page 1 Georgia State University - Confidential MBA 7020 Business Analysis Foundations Simulation July 11, 2005.
1 SIMULATION – PART I Introduction to Simulation and Its Application to Yield Management For this portion of the session, the learning objectives are:
1 Monte-Carlo Simulation Simulation with Spreadsheets.
Session 7b. Decision Models -- Prof. Juran2 Example: Preventive Maintenance At the beginning of each week, a machine is in one of four conditions: 1 =
Contemporary Engineering Economics, 4 th edition, © 2007 Risk Simulation Lecture No. 49 Chapter 12 Contemporary Engineering Economics Copyright, © 2006.
LSP 121 final exam review. 1) The Pacific tectonic plate moves at a rate of 4”/year. What is this in miles per hour? 4 in x yr x da x ft x mi yr 365 da.
Macros Excel built-in functions are great but limited Macros are a means for the user to define new functions A macro is a single command that automates.
Monte Carlo Methods A Monte Carlo simulation creates samples from a known distribution For example, if you know that a coin is weighted so that heads will.
UNCLASSIFIED Schopenhauer's Proof For Software: Pessimistic Bias In the NOSTROMO Tool (U) Dan Strickland Dynetics Program Software Support
Excel For MATH 125 Histograms. If you have Excel 2003…
Using Visual Basic for Applications (VBA) Jake Blanchard University of Wisconsin Spring 2010.
Financial Simulation N. Gershun. Overview is a spreadsheet add-in that has two advantages. provides easy access.
Simulation.
Delivering Integrated, Sustainable, Water Resources Solutions Monte Carlo Simulation Robert C. Patev North Atlantic Division – Regional Technical.
COMPREHENSIVE Excel Tutorial 8 Developing an Excel Application.
Monte Carlo Simulation 1.  Simulations where random values are used but the explicit passage of time is not modeled Static simulation  Introduction.
Lecture 11 Implementation Issues – Part 2. Monte Carlo Simulation An alternative approach to valuing embedded options is simulation Underlying model “simulates”
Introduction to VBA. This is not Introduction to Excel We’re going to assume you have a basic level of familiarity with Excel If you don’t, or you need.
Monte Carlo Methods A Monte Carlo simulation creates samples from a known distribution For example, if you know that a coin is weighted so that heads will.
Introduction to Excel VBA University of Chicago Graduate School of Business Introduction to Computer Based Models Bus Mr. Schrage Spring 2003.
Microsoft Excel Macros & Excel Solver (IENG490)
1 Visual Basic for Applications (VBA) for Excel Prof. Yitzchak Rosenthal.
Exercises of computational methods in finance
597 APPLICATIONS OF PARAMETERIZATION OF VARIABLES FOR MONTE-CARLO RISK ANALYSIS Teaching Note (MS-Excel)
The AIE Monte Carlo Tool The AIE Monte Carlo tool is an Excel spreadsheet and a set of supporting macros. It is the main tool used in AIE analysis of a.
Probabilistic Mechanism Analysis. Outline Uncertainty in mechanisms Why consider uncertainty Basics of uncertainty Probabilistic mechanism analysis Examples.
Chapter 10 Introduction to Simulation Modeling Monte Carlo Simulation.
SIMULATION USING CRYSTAL BALL. WHAT CRYSTAL BALL DOES? Crystal ball extends the forecasting capabilities of spreadsheet model and provide the information.
ESD.70J Engineering Economy Module - Session 21 ESD.70J Engineering Economy Module Fall 2005 Session One Alex Fadeev - Link for this PPT:
Excel Spreadsheet Project 1. Objective: Begin to see the possibilities of Excel How to gather and organize data Entering formula’s Convert data into graphs.
Contemporary Engineering Economics, 6 th edition Park Copyright © 2016 by Pearson Education, Inc. All Rights Reserved Risk Simulation Lecture No. 40 Chapter.
Jake Blanchard University of Wisconsin Spring 2006.
Crystal Ball: Risk Analysis  Risk analysis uses analytical decision models or Monte Carlo simulation models based on the probability distributions to.
Outline of Chapter 9: Using Simulation to Solve Decision Problems Real world decisions are often too complex to be analyzed effectively using influence.
Simulation is the process of studying the behavior of a real system by using a model that replicates the behavior of the system under different scenarios.
ESD.70J Engineering Economy Module - Session 21 ESD.70J Engineering Economy Fall 2006 Session Two Alex Fadeev - Link for this PPT:
Chapter 3 The Visual Basic Editor. Important Features of the VBE Alt-F11 will open the Visual Basic Editor. The Code window is to the right, Project Explorer.
A Different Type of Monte Carlo Simulation Jake Blanchard Spring 2010 Uncertainty Analysis for Engineers1.
ESD.70J Engineering Economy Module - Session 21 ESD.70J Engineering Economy Fall 2009 Session Two Michel-Alexandre Cardin – Prof. Richard.
Monte Carlo Process Risk Analysis for Water Resources Planning and Management Institute for Water Resources 2008.
Simulation is the process of studying the behavior of a real system by using a model that replicates the system under different scenarios. A simulation.
Chapter 7 Sampling Distributions. Sampling Distribution of the Mean Inferential statistics –conclusions about population Distributions –if you examined.
1 In Microsoft Office 2007, click on the Windows button and select the Excel Options button on the lower right From Excel Options, select Trust Center.
Latin Hypercube Sampling Example Jake Blanchard Spring 2010 Uncertainty Analysis for Engineers1.
ESD.70J Engineering Economy Module - Session 21 ESD.70J Engineering Economy Fall 2010 Session Two Xin Zhang – Prof. Richard de Neufville.
1 Using Excel for Statistics in Gateway Cases Office 2007 & 2010.
HMP Simulation - Introduction Deterministic vs. Stochastic Models Risk Analysis Random Variables Best Case/Worst Case Analysis What-If Analysis.
Cuby tutorial Github :
COMPREHENSIVE Excel Tutorial 12 Expanding Excel with Visual Basic for Applications.
Introduction to Simulation Chapter 12. Introduction to Simulation  In many spreadsheets, the value for one or more cells representing independent variables.
Setting up Solver Add-in for Excel
Excel Tutorial 8 Developing an Excel Application
IE 8580 Module 4: DIY Monte Carlo Simulation
Installing Analysis Tool Pak
Prepared by Lloyd R. Jaisingh
Monte Carlo Simulation
Analysis Using Spreadsheets
Microsoft Office Illustrated
Lecture 5 – Improved Monte Carlo methods in finance: lab
Creating Macros in Excel
أ.إسراء الطريقي أ. هاله الشملان , 102 تقن , المعمل الخامس
Installing Analysis Tool Pak
Introduction to Crystal Ball (Part I)
Chapter 6 Lesson 5.
Microsoft Excel 2007 – Level 2
Presentation transcript:

Monte Carlo Simulation in Excel Jake Blanchard Spring 2010 Uncertainty Analysis for Engineers1

Monte Carlo Simulation in Excel There are at least three ways to do MCS in Excel ◦ Fill a bunch of cells with appropriate random numbers ◦ Write a macro in VBA ◦ Use an add-in (Crystal etc.) Uncertainty Analysis for Engineers2

Filling Cells Advantages ◦ Everyone has Excel ◦ Everyone is familiar with formulas in cells Disadvantages ◦ Slow ◦ Cumbersome if you need many samples ◦ Not many built-in distributions Uncertainty Analysis for Engineers3

Typical Sheet Uncertainty Analysis for Engineers4

Formulas 5

Scripting in VBA Start editor from Developer Tab in Excel 2007 If you don’t see Developer Tab, Go to Office Button in upper left and then to Excel Options (at bottom of window) Once editor opens, go to Insert/Module in VBA editor Then paste in script on next page Uncertainty Analysis for Engineers6

The Script Function dice(N, above) Count = 0 For i = 1 To N roll1 = Ceil(6 * Rnd) roll2 = Ceil(6 * Rnd) tot = roll1 + roll2 If tot > above Then Count = Count + 1 End If Next dice = Count / N End Function Public Function Ceil(ByVal X As Double) As Double Ceil = (Int(X) - (X - Int(X) > 0)) End Function Uncertainty Analysis for Engineers7

Built-In Tools Crystal Ball both add Monte Carlo Simulation capability into Excel ◦ Build a model, assuming all parameters are deterministic ◦ Replace random variables with appropriate pdf’s ◦ Identify output variables ◦ Run simulation ◦ Look at output Uncertainty Analysis for Engineers8