統計計算與模擬 政治大學統計系余清祥 2003 年 5 月 26 日 ~ 6 月 3 日 第十四、十五週:蒙地卡羅積分

Slides:



Advertisements
Similar presentations
Lesson 10: Linear Regression and Correlation
Advertisements

The Simple Regression Model
CHAPTER 8 More About Estimation. 8.1 Bayesian Estimation In this chapter we introduce the concepts related to estimation and begin this by considering.
Chapter 7 Numerical Differentiation and Integration
Today’s class Romberg integration Gauss quadrature Numerical Methods
統計計算與模擬 政治大學統計系余清祥 2003 年 6 月 9 日 ~ 6 月 10 日 第十六週:估計密度函數
Discrete Random Variables and Probability Distributions
Chapter 4 Multiple Regression.
Chapter 6 Continuous Random Variables and Probability Distributions
Evaluating Hypotheses
1 1 Slide 統計學 Spring 2004 授課教師:統計系余清祥 日期: 2004 年 5 月 4 日 第十二週:複迴歸.
1 Sociology 601, Class 4: September 10, 2009 Chapter 4: Distributions Probability distributions (4.1) The normal probability distribution (4.2) Sampling.
Statistical Background
Chapter 8 Estimation: Single Population
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 22 Integration of Equations.
Statistics for Managers Using Microsoft Excel, 4e © 2004 Prentice-Hall, Inc. Chap 6-1 Chapter 6 The Normal Distribution and Other Continuous Distributions.
Continuous Random Variables and Probability Distributions
8 TECHNIQUES OF INTEGRATION. There are two situations in which it is impossible to find the exact value of a definite integral. TECHNIQUES OF INTEGRATION.
1 A MONTE CARLO EXPERIMENT In the previous slideshow, we saw that the error term is responsible for the variations of b 2 around its fixed component 
Discrete and Continuous Probability Distributions.
Lecture II-2: Probability Review
Chapter 9 Numerical Integration Numerical Integration Application: Normal Distributions Copyright © The McGraw-Hill Companies, Inc. Permission required.
Business Statistics, A First Course (4e) © 2006 Prentice-Hall, Inc. Chap 8-1 Chapter 8 Confidence Interval Estimation Business Statistics, A First Course.
Elec471 Embedded Computer Systems Chapter 4, Probability and Statistics By Prof. Tim Johnson, PE Wentworth Institute of Technology Boston, MA Theory and.
Quadrature Greg Beckham. Quadrature Numerical Integration Goal is to obtain the integral with as few computations of the integrand as possible.
Physics 114: Lecture 15 Probability Tests & Linear Fitting Dale E. Gary NJIT Physics Department.
1 CE 530 Molecular Simulation Lecture 7 David A. Kofke Department of Chemical Engineering SUNY Buffalo
Common Probability Distributions in Finance. The Normal Distribution The normal distribution is a continuous, bell-shaped distribution that is completely.
Confidence Interval Estimation
Analysis of Monte Carlo Integration Fall 2012 By Yaohang Li, Ph.D.
1 Statistical Mechanics and Multi- Scale Simulation Methods ChBE Prof. C. Heath Turner Lecture 11 Some materials adapted from Prof. Keith E. Gubbins:
Short Resume of Statistical Terms Fall 2013 By Yaohang Li, Ph.D.
Chapter 6: Probability Distributions
PROBABILITY & STATISTICAL INFERENCE LECTURE 3 MSc in Computing (Data Analytics)
Population All members of a set which have a given characteristic. Population Data Data associated with a certain population. Population Parameter A measure.
General Principle of Monte Carlo Fall 2013 By Yaohang Li, Ph.D.
Theory of Probability Statistics for Business and Economics.
Statistics for Managers Using Microsoft Excel, 4e © 2004 Prentice-Hall, Inc. Chap 6-1 Chapter 6 The Normal Distribution and Other Continuous Distributions.
Statistical Decision Making. Almost all problems in statistics can be formulated as a problem of making a decision. That is given some data observed from.
Correlation and Linear Regression. Evaluating Relations Between Interval Level Variables Up to now you have learned to evaluate differences between the.
Maximum Likelihood Estimator of Proportion Let {s 1,s 2,…,s n } be a set of independent outcomes from a Bernoulli experiment with unknown probability.
1 Lesson 8: Basic Monte Carlo integration We begin the 2 nd phase of our course: Study of general mathematics of MC We begin the 2 nd phase of our course:
Integrals  In Chapter 2, we used the tangent and velocity problems to introduce the derivative—the central idea in differential calculus.  In much the.
MGS3100_04.ppt/Sep 29, 2015/Page 1 Georgia State University - Confidential MGS 3100 Business Analysis Regression Sep 29 and 30, 2015.
June 11, 2008Stat Lecture 10 - Review1 Midterm review Chapters 1-5 Statistics Lecture 10.
Risk Analysis & Modelling Lecture 2: Measuring Risk.
Chapter 2 Statistical Background. 2.3 Random Variables and Probability Distributions A variable X is said to be a random variable (rv) if for every real.
CHAPTER 3 NUMERICAL METHODS
PROBABILITY AND STATISTICS FOR ENGINEERING Hossein Sameti Department of Computer Engineering Sharif University of Technology Mean, Variance, Moments and.
Confidence Interval Estimation For statistical inference in decision making:
Expectation. Let X denote a discrete random variable with probability function p(x) (probability density function f(x) if X is continuous) then the expected.
Copyright © 2014 by McGraw-Hill Higher Education. All rights reserved. Essentials of Business Statistics: Communicating with Numbers By Sanjiv Jaggia and.
Review of Probability. Important Topics 1 Random Variables and Probability Distributions 2 Expected Values, Mean, and Variance 3 Two Random Variables.
Probability and Distributions. Deterministic vs. Random Processes In deterministic processes, the outcome can be predicted exactly in advance Eg. Force.
1 Mean Analysis. 2 Introduction l If we use sample mean (the mean of the sample) to approximate the population mean (the mean of the population), errors.
Analysis of Experimental Data; Introduction
1 6. Mean, Variance, Moments and Characteristic Functions For a r.v X, its p.d.f represents complete information about it, and for any Borel set B on the.
Chapter 20 Statistical Considerations Lecture Slides The McGraw-Hill Companies © 2012.
Measurements and Their Analysis. Introduction Note that in this chapter, we are talking about multiple measurements of the same quantity Numerical analysis.
CHAPTER- 3.2 ERROR ANALYSIS. 3.3 SPECIFIC ERROR FORMULAS  The expressions of Equations (3.13) and (3.14) were derived for the general relationship of.
Chapter 8 Estimation ©. Estimator and Estimate estimator estimate An estimator of a population parameter is a random variable that depends on the sample.
統計計算與模擬 政治大學統計系余清祥 2004 年 3 月 15~24 日 第五、六週: 隨機變數模擬
STATISTICS People sometimes use statistics to describe the results of an experiment or an investigation. This process is referred to as data analysis or.
Statistical Decision Making. Almost all problems in statistics can be formulated as a problem of making a decision. That is given some data observed from.
THE NORMAL DISTRIBUTION
Lesson 8: Basic Monte Carlo integration
Normal Distribution and Parameter Estimation
SKTN 2393 Numerical Methods for Nuclear Engineers
政治大學統計系余清祥 2004年5月26日~ 6月7日 第十六、十七週:估計密度函數
政治大學統計系余清祥 2004年5月17日~ 5月26日 第十四、十五週:蒙地卡羅積分 、縮減變異數
Presentation transcript:

統計計算與模擬 政治大學統計系余清祥 2003 年 5 月 26 日 ~ 6 月 3 日 第十四、十五週:蒙地卡羅積分

Variance Reduction Since the standard error reduces at the rate of, we need to increase the size of experiment to f 2 if a factor of f is needed in reducing the standard error.  However, larger sample size means higher cost in computer. We shall introduce methods for reducing standard errors, including Importance sampling, Control and Antithetic variates.

Monte-Carlo Integration  Suppose we wish to evaluate After sampling independently from f and form i.e., the precision of is proportion to. (In numerical integration, n points can achieve the precision of.)

Question: We can use Riemann integral to evaluate definite integrals. Then why do we need Monte Carlo integration?  As the number of dimensions k increases, the number of points n required to achieve a fair estimate of integral would increase dramatically, i.e., proportional to n k.  Even when the value k is small, if the function to integrated is irregular, then it would inefficient to use the regular methods of integration.

Numerical integration  Also named as “quadrature,” it is related to the evaluation of the integral is precisely equivalent to solving for the value I  y(b) the differential equation with the boundary condition y(a) = 0.

 Classical formula is known at equally spaced steps. The only differences are on if the end points, i.e., a and b, of function f are used. If they are (are not), it is called a closed (open) formula. (Only one is used is called semi- open).

Question: What is your intuitive idea of calculating an integral, such as Ginni’s index (in a Lorenz curve)?

 We shall denote the equal spaced points as which are spaced apart by a constant step h, i.e., We shall focus on the integration between any two consecutive x’s points, i.e.,, and the integration between a and b can be divided into integrating a function over a number of smaller intervals.

Closed Newton-Cotes Formulas  Trapezoidal rule: Here the error term O( ) signifies that the true answer differs from the estimate by an amount that is the product of some numerical coefficient times h 3 times f ’’. In other words, the error of the integral on (a,b) using Trapezoidal rule is about O(n –2 ).

 Simpson’s rule: Extended Trapezoidal rule:

 Extended formula of order 1/N 3 :  Extended Simpson’s rule:

Example 1. If C is a Cauchy deviate, then estimate.  If X ~ Cauchy, then i.e., (1) (2) Compute by setting

(3) Since let then we can get (4) Let y = 1/x in (3), then Using transformation on and Y i ~ U(0,1/2), we have Note: The largest reduction is

Importance Sampling:  In evaluating  = E  (X), some outcomes of X may be more important. (Take  as the prob. of the occurrence of a rare event  produce more rare event.)  Idea: Simulate from p.d.f. g (instead of the true f ). Let Here, is unbiased estimate of , and Can be very small if is close to a constant.

Example 1 (continued) We select g so that For x >2, is closely matched by, i.e., sampling X = 2/U, U ~ U(0,1), and let By this is equivalent to (4). We shall use simulation to check.

Note: We can see that all methods have unbiased estimates, since   (1)(2)(3)(4) 10,000 runs e-5 50,000 runs e-5 100,000 runs e-5 Ratio

Example 2. Evaluate the CDF of standard normal dist.:  Note that  (y) has similar shape as the logistic, i.e., k is a normalization constant, i..e.,

 We can therefore estimate  (x) by where y i ’s is a random sample from g(y)/k. In other words,

xn=100n=1000n=5000 Φ (x) Note: The differences between estimates and the true values are at the fourth decimal.

Control Variate:  Suppose we wish to estimate  = E(Z) for some Z =  (X) observed in a process of X. Take another observation W =  (X), which we believe varies with Z and which has a known mean. We can then estimate  by averaging observations of Z – (W – E(W)). For example, we can use “sample mean” to reduce the variance of “sample median.”

Example 3. We want to find median of Poisson(11.5) for a set of 100 observations.  Similar to the idea of bivariate normal distribution, we can modify the estimate as median(X) –  (median,mean)  (sample mean – grand average) As a demonstration, we repeat simulation 20 Times (of 100 obs.) and get MedianAve.=11.35Var.= ControlAve.=11.35Var.=0.2294

Control Variate (continued)  In general, suppose there are p control variates W 1, …, W p and Z generally varies with each W i, i.e., and is unbiased. For example, consider p = 1, i.e., and the min. is attained when  Multiple regression of Z on W 1, …, W p.

Example 1(continued). Use control variate to reduce the variance. We shall use and Note: These two are the modified version of (3) and (4) in the previous case.

Based on 10,000 simulation runs, we can see the effect of control variate from the following table: (3)(3)c(4)(4)c Ave Var e-49.6e-51.1e-9 Note: The control variate of (4) can achieve a reduction of 1.1  10 8 times.

Table 1. Variance Reduction for the Ratio Method ( μ x,μ y,ρ,σ x,σ y ) = (2, 3, 0.95, 0.2, 0.3 ) ( )( ) ( )( )

Question: How do we find the estimates of correlation coefficients between Z and W’s?  For example, in the previous case, the range of x is (0,2) and so we can divide this range into x = 0.01, 0.02, …, 2. Then fit a regression equation on f(x), based on x 2 and x 4. The regression coefficients derived are the correlation coefficients between f(x) and x’s. Similarly, we can add the terms x and x 3 if necessary. Question: How do we handle multi-collineaity?

Antithetic Variate:  Suppose Z* has the same dist. as Z but is negatively correlated with Z. Suppose we estimate  by is unbiased and If Corr(Z,Z*) < 0, then a smaller variance is attained. Usually, we set Z = F -1 (U) and Z* = F -1 (1-U)  Corr(Z,Z*) < 0.

Example 1(continued). Use Antithetic variate to reduce variances of (3) and (4). (3)(3)a(4)(4)a Ave Var e-49.6e e-6 Note: The antithetic variate on (4) does not reduce as much as the case in control variate.

Note: Consider the integral which is usually estimated by while the estimate via antithetic variate is  For symmetric dist., we can obtain perfect negative correlation. Consider the Bernoulli dist. with P(Z = 1) = 1 – P(Z = 0) = p. Then

 The general form of antithetic variate is  Thus, it is of no use to let Z* = 1 – Z if p  0 or p  1, since only a minor reduction in variance is possible.

Conditioning:  In general, we have  Example 4. Want to estimate . We did it before by V i = 2U i – 1, i =1, 2, and set We can improve the estimate E(I) by using E(I|V 1 ).

Thus, has mean  /4 (check this!) and a smaller variance. Also, the conditional variance equals to smaller than