NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 1 Lecture 6 Slide 1 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall.

Slides:



Advertisements
Similar presentations
Modeling of Data. Basic Bayes theorem Bayes theorem relates the conditional probabilities of two events A, and B: A might be a hypothesis and B might.
Advertisements

Design of Experiments Lecture I
Welcome to PHYS 225a Lab Introduction, class rules, error analysis Julia Velkovska.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 ~ Curve Fitting ~ Least Squares Regression Chapter.
CmpE 104 SOFTWARE STATISTICAL TOOLS & METHODS MEASURING & ESTIMATING SOFTWARE SIZE AND RESOURCE & SCHEDULE ESTIMATING.
Regression Analysis Once a linear relationship is defined, the independent variable can be used to forecast the dependent variable. Y ^ = bo + bX bo is.
Ch11 Curve Fitting Dr. Deshi Ye
Chapter 10 Simple Regression.
G. Cowan Lectures on Statistical Data Analysis 1 Statistical Data Analysis: Lecture 10 1Probability, Bayes’ theorem, random variables, pdfs 2Functions.
Least Square Regression
Curve-Fitting Regression
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 17 Least Square Regression.
SIMPLE LINEAR REGRESSION
Chapter 11 Multiple Regression.
Lecture 16 – Thurs, Oct. 30 Inference for Regression (Sections ): –Hypothesis Tests and Confidence Intervals for Intercept and Slope –Confidence.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. by Lale Yurttas, Texas A&M University Chapter 171 CURVE.
SIMPLE LINEAR REGRESSION
Chapter 14 Introduction to Linear Regression and Correlation Analysis
Correlation and Regression Analysis
Simple Linear Regression Analysis
Simple Linear Regression. Introduction In Chapters 17 to 19, we examine the relationship between interval variables via a mathematical equation. The motivation.
Modern Navigation Thomas Herring
Regression and Correlation Methods Judy Zhong Ph.D.
SIMPLE LINEAR REGRESSION
Least-Squares Regression
Physics 114: Lecture 15 Probability Tests & Linear Fitting Dale E. Gary NJIT Physics Department.
Regression Analysis Regression analysis is a statistical technique that is very useful for exploring the relationships between two or more variables (one.
LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 1 Lecture 5 Slide 1 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall.
Regression Analysis (2)
Introduction to Error Analysis
Copyright © 2013, 2010 and 2007 Pearson Education, Inc. Chapter Inference on the Least-Squares Regression Model and Multiple Regression 14.
Chapter 15 Modeling of Data. Statistics of Data Mean (or average): Variance: Median: a value x j such that half of the data are bigger than it, and half.
Stats for Engineers Lecture 9. Summary From Last Time Confidence Intervals for the mean t-tables Q Student t-distribution.
Lecture 12 Statistical Inference (Estimation) Point and Interval estimation By Aziza Munir.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 4 Curve Fitting.
Review of Probability Concepts ECON 4550 Econometrics Memorial University of Newfoundland Adapted from Vera Tabakova’s notes SECOND.
Chap 12-1 A Course In Business Statistics, 4th © 2006 Prentice-Hall, Inc. A Course In Business Statistics 4 th Edition Chapter 12 Introduction to Linear.
Applied Quantitative Analysis and Practices LECTURE#23 By Dr. Osman Sadiq Paracha.
Chapter 8 Curve Fitting.
Curve-Fitting Regression
10B11PD311 Economics REGRESSION ANALYSIS. 10B11PD311 Economics Regression Techniques and Demand Estimation Some important questions before a firm are.
Selecting Input Probability Distribution. Simulation Machine Simulation can be considered as an Engine with input and output as follows: Simulation Engine.
CHEMISTRY ANALYTICAL CHEMISTRY Fall Lecture 6.
LECTURE 3: ANALYSIS OF EXPERIMENTAL DATA
Multiple Regression. Simple Regression in detail Y i = β o + β 1 x i + ε i Where Y => Dependent variable X => Independent variable β o => Model parameter.
Ch14: Linear Least Squares 14.1: INTRO: Fitting a pth-order polynomial will require finding (p+1) coefficients from the data. Thus, a straight line (p=1)
DISTRIBUTION FUNCTIONS Introduction Section 0 Lecture 1 Slide 1 Lecture 3 Slide 1 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870.
Economics 173 Business Statistics Lecture 10 Fall, 2001 Professor J. Petry
Copyright © 2011 by The McGraw-Hill Companies, Inc. All rights reserved. McGraw-Hill/Irwin Simple Linear Regression Analysis Chapter 13.
Statistics Presentation Ch En 475 Unit Operations.
1 1 Slide The Simple Linear Regression Model n Simple Linear Regression Model y =  0 +  1 x +  n Simple Linear Regression Equation E( y ) =  0 + 
Statistics 350 Lecture 2. Today Last Day: Section Today: Section 1.6 Homework #1: Chapter 1 Problems (page 33-38): 2, 5, 6, 7, 22, 26, 33, 34,
R. Kass/Sp07P416/Lecture 71 More on Least Squares Fit (LSQF) In Lec 5, we discussed how we can fit our data points to a linear function (straight line)
Bivariate Regression. Bivariate Regression analyzes the relationship between two variables. Bivariate Regression analyzes the relationship between two.
The simple linear regression model and parameter estimation
Physics 114: Lecture 13 Probability Tests & Linear Fitting
Part 5 - Chapter
Part 5 - Chapter 17.
Parameter Estimation and Fitting to Data
Ch3: Model Building through Regression
Physics 114: Exam 2 Review Material from Weeks 7-11
Review of Probability Concepts
CHAPTER 29: Multiple Regression*
Chapter 12 Curve Fitting : Fitting a Straight Line Gab-Byung Chae
CHAPTER 26: Inference for Regression
Part 5 - Chapter 17.
Linear regression Fitting a straight line to observations.
Regression Lecture-5 Additional chapters of mathematics
Simple Linear Regression
Presentation transcript:

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 1 Lecture 6 Slide 1 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Intermediate Lab PHYS 3870 Lecture 5 Comparing Data and Models— Quantitatively Non-linear Regression References: Taylor Ch. 9, 12 Also refer to “Glossary of Important Terms in Error Analysis”

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 2 Lecture 6 Slide 2 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Intermediate Lab PHYS 3870 Errors in Measurements and Models A Review of What We Know

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 3 Lecture 6 Slide 3 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Quantifying Precision and Random (Statistical) Errors

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 4 Lecture 6 Slide 4 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Single Measurement: Comparison with Other Data Comparison of precision or accuracy?

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 5 Lecture 6 Slide 5 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Single Measurement: Direct Comparison with Standard Comparison of precision or accuracy?

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 6 Lecture 6 Slide 6 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Multiple Measurements of the Same Quantity

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 7 Lecture 6 Slide 7 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Standard Deviation Multiple Measurements of the Same Quantity

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 8 Lecture 6 Slide 8 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Standard Deviation of the Mean Multiple Measurements of the Same Quantity

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 9 Lecture 6 Slide 9 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Errors in Models—Error Propagation

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 10 Lecture 6 Slide 10 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Specific Rules for Error Propogation

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 11 Lecture 6 Slide 11 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 General Formula for Error Propagation

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 12 Lecture 6 Slide 12 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 General Formula for Multiple Variables

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 13 Lecture 6 Slide 13 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Error for a function of Two Variables: Addition in Quadrature Consider the arbitrary derived quantity q(x,y) of two independent random variables x and y. Expand q(x,y) in a Taylor series about the expected values of x and y (i.e., at points near X and Y). Error Propagation: General Case Fixed, shifts peak of distribution FixedDistribution centered at X with width σ X

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 14 Lecture 6 Slide 14 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Independent (Random) Uncertaities and Gaussian Distributions

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 15 Lecture 6 Slide 15 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Gaussian Distribution Function Width of Distribution (standard deviation) Center of Distribution (mean) Distribution Function Independent Variable Gaussian Distribution Function Normalization Constant

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 16 Lecture 6 Slide 16 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Standard Deviation of Gaussian Distribution Area under curve (probability that –σ<x<+σ) is 68% 5% or ~2σ “Significant” 1% or ~3σ “Highly Significant” 1σ “Within errors” 5 ppm or ~5σ “Valid for HEP” See Sec. 10.6: Testing of Hypotheses

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 17 Lecture 6 Slide 17 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Mean of Gaussian Distribution as “Best Estimate” Principle of Maximum Likelihood Best Estimate of X is from maximum probability or minimum summation Consider a data set Each randomly distributed with {x 1, x 2, x 3 …x N } To find the most likely value of the mean (the best estimate of ẋ ), find X that yields the highest probability for the data set. The combined probability for the full data set is the product Minimize Sum Solve for derivative set to 0 Best estimate of X

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 18 Lecture 6 Slide 18 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Uncertaity of “Best Estimates” of Gaussian Distribution Principle of Maximum Likelihood Best Estimate of X is from maximum probability or minimum summation Consider a data set{x 1, x 2, x 3 …x N } To find the most likely value of the mean (the best estimate of ẋ ), find X that yields the highest probability for the data set. The combined probability for the full data set is the product Minimize Sum Solve for derivative wrst X set to 0 Best estimate of X Best Estimate of σ is from maximum probability or minimum summation Minimize Sum Best estimate of σ Solve for derivative wrst σ set to 0 See Prob. 5.26

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 19 Lecture 6 Slide 19 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Weighted Averages Question: How can we properly combine two or more separate independent measurements of the same randomly distributed quantity to determine a best combined value with uncertainty?

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 20 Lecture 6 Slide 20 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Weighted Averages Best Estimate of χ is from maximum probibility or minimum summation Minimize SumSolve for best estimate of χ Solve for derivative wrst χ set to 0 Note: If w 1 =w 2, we recover the standard result X wavg = (1/2) (x 1 +x 2 )

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 21 Lecture 6 Slide 21 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Intermediate Lab PHYS 3870 Comparing Measurements to Linear Models Summary of Linear Regression

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 22 Lecture 6 Slide 22 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Question 1: What is the Best Linear Fit (A and B)? Best Estimate of intercept, A, and slope, B, for Linear Regression or Least Squares- Fit for Line

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 23 Lecture 6 Slide 23 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Best Estimates of A and B are from maximum probibility or minimum summation Minimize SumBest estimate of A and B Solve for derivative wrst A and B set to 0 “Best Estimates” of Linear Fit

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 24 Lecture 6 Slide 24 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Best Estimates of A and B are from maximum probibility or minimum summation Minimize SumBest estimate of A and B Solve for derivative wrst A and B set to 0 “Best Estimates” of Linear Fit

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 25 Lecture 6 Slide 25 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Correlation Coefficient Combining the Schwartz inequality With the definition of the covariance With a limiting value The uncertainty in a function q(x,y) is At last, the upper bound of errors is And for independent and random variables

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 26 Lecture 6 Slide 26 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Question 2: Is it Linear? Consider the limiting cases for: r=0 (no correlation) [for any x, the sum over y-Y yields zero] r=±1 (perfect correlation). [Substitute yi-Y=B(xi-X) to get r=B/|B|=±1] y(x) = A + B x

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 27 Lecture 6 Slide 27 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Tabulated Correlation Coefficient Consider the limiting cases for: r=0 (no correlation) r=±1 (perfect correlation). To gauge the confidence imparted by intermediate r values consult the table in Appendix C. r value N data points Probability that analysis of N=70 data points with a correlation coefficient of r=0.5 is not modeled well by a linear relationship is 3.7%. Therefore, it is very probably that y is linearly related to x. If Prob N (|r|>r o )<32%  it is probably that y is linearly related to x Prob N (|r|>r o )<5%  it is very probably that y is linearly related to x Prob N (|r|>r o )<1%  it is highly probably that y is linearly related to x

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 28 Lecture 6 Slide 28 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Uncertainties in Slope and Intercept Taylor: Relation to R 2 value:

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 29 Lecture 6 Slide 29 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Intermediate Lab PHYS 3870 Comparing Measurements to Models Non-Linear Regression

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 30 Lecture 6 Slide 30 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Motivating Regression Analysis Question: Consider now what happens to the output of a nearly ideal experiment, if we vary how hard we poke the system (vary the input). SYSTEM Input Output Uncertainties in Observations The Universe A more general model of response is a nonlinear response model y(x) = f(x)

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 31 Lecture 6 Slide 31 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Questions for Regression Analysis Two principle questions: What are the best values of a set of fitting parameters, What confidence can we place in how well the general model fits the data? A more general model of response is a nonlinear response model y(x) = f(x) The solutions is familiar: Evoke the Principle of Maximum Likelihood, Minimize the summation of the exponent arguments, that is chi squared? Recall what this looked like for a model with a constant value, linear model, polynomial model, and now a general nonlinear model

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 32 Lecture 6 Slide 32 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Chi Squared Analysis for Least Squares Fit Discrete distribution General definition for Chi squared (square of the normalized deviations) Continuous distribution Perfect model Good model Poor model

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 33 Lecture 6 Slide 33 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Expected Values for Chi Squared Analysis or If the model is “good”, each term in the sum is ~1, so More correctly the sum goes to the number of degrees of freedom, d≡N-c. The reduced Chi-squared value is i i So Χ red 2 =0 for perfect fit Χ red 2 <1 for “good” fit Χ red 2 >1 for “poor” fit (looks a lot like r for linear fits doesn’t it?)

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 34 Lecture 6 Slide 34 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Chi Squared Analysis for Least Squares Fit From the probability table ~99.5% (highly significant) confidence

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 35 Lecture 6 Slide 35 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Probabilities for Chi Squared

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 36 Lecture 6 Slide 36 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Reduced Chi Squared Analysis

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 37 Lecture 6 Slide 37 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Problem 12.2

NON-LINEAR REGRESSION Introduction Section 0 Lecture 1 Slide 38 Lecture 6 Slide 38 INTRODUCTION TO Modern Physics PHYX 2710 Fall 2004 Intermediate 3870 Fall 2011 Problem 12.2