137
Principles of Econometrics, 4t h Edition Page 1 Chapter 2: The Simple Linear Regression Model Chapter 2 The Simple Linear Regression Model: Specification and Estimation Walter R. Paczkowski Rutgers University

Chapter 2 The Simple Linear Regression Model: Specification and Estimation

  • Upload
    nike

  • View
    77

  • Download
    6

Embed Size (px)

DESCRIPTION

Chapter 2 The Simple Linear Regression Model: Specification and Estimation. Walter R. Paczkowski Rutgers University. Chapter Contents. 2.1 An Economic Model 2.2 An Econometric Model 2.3 Estimating the Regression Parameters 2.4 Assessing the Least Squares Estimators - PowerPoint PPT Presentation

Citation preview

Page 1: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 1Chapter 2: The Simple Linear Regression Model

Chapter 2The Simple Linear Regression

Model: Specification and Estimation

Walter R. Paczkowski Rutgers University

Page 2: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 2Chapter 2: The Simple Linear Regression Model

2.1 An Economic Model2.2 An Econometric Model2.3 Estimating the Regression Parameters2.4 Assessing the Least Squares Estimators2.5 The Gauss-Markov Theorem2.6 The Probability Distributions of the Least

Squares Estimators2.7 Estimating the Variance of the Error Term2.8 Estimating Nonlinear Relationships2.9 Regression with Indicator Variables

Chapter Contents

Page 3: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 3Chapter 2: The Simple Linear Regression Model

2.1 An Economic Model

Page 4: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 4Chapter 2: The Simple Linear Regression Model

As economists we are usually more interested in studying relationships between variables– Economic theory tells us that expenditure on

economic goods depends on income – Consequently we call y the ‘‘dependent

variable’’ and x the independent’’ or ‘‘explanatory’’ variable

– In econometrics, we recognize that real-world expenditures are random variables, and we want to use data to learn about the relationship

2.1An Economic

Model

Page 5: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 5Chapter 2: The Simple Linear Regression Model

The pdf is a conditional probability density function since it is ‘‘conditional’’ upon an x– The conditional mean, or expected value, of y is

E(y|x)• The expected value of a random variable is

called its ‘‘mean’’ value, which is really a contraction of population mean, the center of the probability distribution of the random variable• This is not the same as the sample mean,

which is the arithmetic average of numerical values

2.1An Economic

Model

Page 6: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 6Chapter 2: The Simple Linear Regression Model

Figure 2.1a Probability distribution of food expenditure y given income x = $1000

2.1An Economic

Model

Page 7: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 7Chapter 2: The Simple Linear Regression Model

The conditional variance of y is σ2 which measures the dispersion of y about its mean μy|x – The parameters μy|x and σ2, if they were known,

would give us some valuable information about the population we are considering

2.1An Economic

Model

Page 8: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 8Chapter 2: The Simple Linear Regression Model

Figure 2.1b Probability distributions of food expenditures y given incomes x = $1000 and x = $2000

2.1An Economic

Model

Page 9: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 9Chapter 2: The Simple Linear Regression Model

In order to investigate the relationship between expenditure and income we must build an economic model and then a corresponding econometric model that forms the basis for a quantitative or empirical economic analysis– This econometric model is also called a

regression model

2.1An Economic

Model

Page 10: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 10Chapter 2: The Simple Linear Regression Model

Eq. 2.1xxyE y 21)|(

The simple regression function is written as

where β1 is the intercept and β2 is the slope

Eq. 2.1 2 2( | ) μ β βyE y x x

2.1An Economic

Model

Page 11: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 11Chapter 2: The Simple Linear Regression Model

xxyE y 21)|( It is called simple regression not because it is easy, but because there is only one explanatory variable on the right-hand side of the equation

2.1An Economic

Model

Page 12: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 12Chapter 2: The Simple Linear Regression Model

2.1An Economic

ModelFigure 2.2 The economic model: a linear relationship between average per person food expenditure and income

Page 13: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 13Chapter 2: The Simple Linear Regression Model

Eq. 2.2

“Δ” denotes “change in” and “dE(y|x)/dx” denotes the derivative of the expected value of y given an x value

dxxydE

xxyE )|()|(

2

The slope of the regression line can be written as:

where “Δ” denotes “change in” and “dE(y|x)/dx” denotes the derivative of the expected value of y given an x value

Eq. 2.2 2( | ) ( | )β E y x dE y x

x dx

2.1An Economic

Model

Page 14: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 14Chapter 2: The Simple Linear Regression Model

2.2 An Econometric Model

Page 15: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 15Chapter 2: The Simple Linear Regression Model

2.2An Econometric

Model Figure 2.3 The probability density function for y at two levels of income

Page 16: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 16Chapter 2: The Simple Linear Regression Model

There are several key assumptions underlying the simple linear regression–More will be added later

2.2An Econometric

Model

Page 17: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 17Chapter 2: The Simple Linear Regression Model

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - I

Assumption 1:The mean value of y, for each value of x, is

given by the linear regression

1 2( | ) β βE y x x

2.2An Econometric

Model

Page 18: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 18Chapter 2: The Simple Linear Regression Model

Assumption 2:For each value of x, the values of y are

distributed about their mean value, following probability distributions that all have the same

variance2var( | ) σy x

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - I2.2

An Econometric Model

Page 19: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 19Chapter 2: The Simple Linear Regression Model

Assumption 3:The sample values of y are all uncorrelated,

and have zero covariance, implying that there is no linear association among them

0),cov( ji yy

This assumption can be made stronger by assuming that the values of y are all statistically independent

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - I2.2

An Econometric Model

Page 20: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 20Chapter 2: The Simple Linear Regression Model

Assumption 4:The variable x is not random, and must take at

least two different values

2.2An Econometric

Model ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - I

Page 21: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 21Chapter 2: The Simple Linear Regression Model

Assumption 5:

(optional) The values of y are normally distributed about their mean for each value of x

21 2~ (β β ,σ )y N x

2.2An Econometric

Model ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - I

Page 22: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 22Chapter 2: The Simple Linear Regression Model

2.2.1Introducing the

Error TermThe random error term is defined as

– Rearranging gives

where y is the dependent variable and x is the independent variable

1 2| β βe y E y x y x Eq. 2.3

1 2β βy x e Eq. 2.4

2.2An Econometric

Model

Page 23: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 23Chapter 2: The Simple Linear Regression Model

The expected value of the error term, given x, is

The mean value of the error term, given x, is zero

1 2( | ) ( | ) β β 0E e x E y x x

2.2An Econometric

Model

2.2.1Introducing the

Error Term

Page 24: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 24Chapter 2: The Simple Linear Regression Model

Figure 2.4 Probability density functions for e and y2.2

An Econometric Model

2.2.1Introducing the

Error Term

Page 25: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 25Chapter 2: The Simple Linear Regression Model

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Assumption SR1:The value of y, for each value of x, is:

1 2β βy x e

2.2An Econometric

Model

2.2.1Introducing the

Error Term

Page 26: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 26Chapter 2: The Simple Linear Regression Model

Assumption SR2:The expected value of the random error e is:

This is equivalent to assuming that

0)( eE

1 2( ) β βE y x

2.2An Econometric

Model

2.2.1Introducing the

Error Term

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Page 27: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 27Chapter 2: The Simple Linear Regression Model

Assumption SR3:The variance of the random error e is:

2var( ) σ var( )e y

The random variables y and e have the same variance because they differ only by a constant.

2.2An Econometric

Model

2.2.1Introducing the

Error Term

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Page 28: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 28Chapter 2: The Simple Linear Regression Model

Assumption SR4:The covariance between any pair of random

errors, ei and ej is:

The stronger version of this assumption is that the random errors e are statistically independent, in which case the values of the dependent variable y are also statistically independent

0),cov(),cov( jiji yyee

2.2An Econometric

Model

2.2.1Introducing the

Error Term

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Page 29: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 29Chapter 2: The Simple Linear Regression Model

Assumption SR5:The variable x is not random, and must take at

least two different values

2.2An Econometric

Model

2.2.1Introducing the

Error Term

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Page 30: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 30Chapter 2: The Simple Linear Regression Model

Assumption SR6:(optional) The values of e are normally

distributed about their mean if the values of y are normally distributed, and vice versa

2~ (0,σ )e N

2.2An Econometric

Model

2.2.1Introducing the

Error Term

ASSUMPTIONS OF THE SIMPLE LINEAR REGRESSION MODEL - II

Page 31: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 31Chapter 2: The Simple Linear Regression Model

Figure 2.5 The relationship among y, e and the true regression line2.2

An Econometric Model

2.2.1Introducing the

Error Term

Page 32: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 32Chapter 2: The Simple Linear Regression Model

2.3 Estimating the Regression Parameters

Page 33: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 33Chapter 2: The Simple Linear Regression Model

2.3Estimating the

Regression Parameters

Table 2.1 Food Expenditure and Income Data

Page 34: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 34Chapter 2: The Simple Linear Regression Model

Figure 2.6 Data for food expenditure example2.3

Estimating the Regression Parameters

Page 35: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 35Chapter 2: The Simple Linear Regression Model

The fitted regression line is:

The least squares residual is:

2.3.1The Least Squares Principle

1 2ˆi iy b b x

iiiii xbbyyye 21ˆˆ

Eq. 2.5

Eq. 2.6

2.3Estimating the

Regression Parameters

Page 36: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 36Chapter 2: The Simple Linear Regression Model

Figure 2.7 The relationship among y, ê and the fitted regression line2.3

Estimating the Regression Parameters

2.3.1The Least Squares Principle

Page 37: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 37Chapter 2: The Simple Linear Regression Model

Suppose we have another fitted line:

The least squares line has the smaller sum of squared residuals:

* * *1 2ˆi iy b b x

*

1

2**

1

2 thenˆandˆif SSESSEeSSEeSSEN

ii

N

ii

2.3Estimating the

Regression Parameters

2.3.1The Least Squares Principle

Page 38: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 38Chapter 2: The Simple Linear Regression Model

Least squares estimates for the unknown parameters β1 and β2 are obtained my minimizing the sum of squares function:

21 2 1 2

1

(β ,β ) ( β β )N

i ii

S y x

2.3Estimating the

Regression Parameters

2.3.1The Least Squares Principle

Page 39: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 39Chapter 2: The Simple Linear Regression Model

22 )())((

xxyyxx

bi

ii

xbyb 21

Eq. 2.7

Eq. 2.8

2.3Estimating the

Regression Parameters

2.3.1The Least Squares Principle

THE LEAST SQUARES ESTIMATORS

Page 40: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 40Chapter 2: The Simple Linear Regression Model

2.3.2Estimates for

the Food Expenditure

Function

2096.107876.18282684.18671

)())((

22

xxyyxx

bi

ii

4160.83)6048.19)(2096.10(5735.28321 xbyb

A convenient way to report the values for b1 and b2 is to write out the estimated or fitted regression line:

ii xy 21.1042.83ˆ

2.3Estimating the

Regression Parameters

Page 41: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 41Chapter 2: The Simple Linear Regression Model

Figure 2.8 The fitted regression line2.3

Estimating the Regression Parameters

2.3.2Estimates for

the Food Expenditure

Function

Page 42: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 42Chapter 2: The Simple Linear Regression Model

The value b2 = 10.21 is an estimate of 2, the amount by which weekly expenditure on food per household increases when household weekly income increases by $100. Thus, we estimate that if income goes up by $100, expected weekly expenditure on food will increase by approximately $10.21– Strictly speaking, the intercept estimate b1 =

83.42 is an estimate of the weekly food expenditure on food for a household with zero income

2.3.3Interpreting the

Estimates

2.3Estimating the

Regression Parameters

Page 43: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 43Chapter 2: The Simple Linear Regression Model

Income elasticity is a useful way to characterize the responsiveness of consumer expenditure to changes in income. The elasticity of a variable y with respect to another variable x is:

In the linear economic model given by Eq. 2.1 we have shown that

2.3.3aElasticities

yx

xy

xy

in change percentagein change percentage

2( )β E yx

2.3Estimating the

Regression Parameters

Page 44: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 44Chapter 2: The Simple Linear Regression Model

The elasticity of mean expenditure with respect to income is:

A frequently used alternative is to calculate the elasticity at the “point of the means” because it is a representative point on the regression line.

2( ) ( ) ( ) β

( ) ( )E y E y E y x x

x x x E y E y

Eq. 2.9

71.057.283

60.1921.10ˆ 2 yxb

2.3Estimating the

Regression Parameters

2.3.3aElasticities

Page 45: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 45Chapter 2: The Simple Linear Regression Model

Suppose that we wanted to predict weekly food expenditure for a household with a weekly income of $2000. This prediction is carried out by substituting x = 20 into our estimated equation to obtain:

We predict that a household with a weekly income of $2000 will spend $287.61 per week on food

2.3.3bPrediction

61.287)20(21.1042.8321.1042.83ˆ ixy

2.3Estimating the

Regression Parameters

Page 46: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 46Chapter 2: The Simple Linear Regression Model

2.3.3cComputer

Output

Figure 2.9 EViews Regression Output2.3

Estimating the Regression Parameters

Page 47: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 47Chapter 2: The Simple Linear Regression Model

2.3.4Other Economic

Models

The simple regression model can be applied to estimate the parameters of many relationships in economics, business, and the social sciences – The applications of regression analysis are

fascinating and useful

2.3Estimating the

Regression Parameters

Page 48: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 48Chapter 2: The Simple Linear Regression Model

2.4 Assessing the Least Squares Fit

Page 49: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 49Chapter 2: The Simple Linear Regression Model

We call b1 and b2 the least squares estimators.– We can investigate the properties of the estimators

b1 and b2 , which are called their sampling properties, and deal with the following important questions:

1. If the least squares estimators are random variables, then what are their expected values, variances, covariances, and probability distributions?

2. How do the least squares estimators compare with other procedures that might be used, and how can we compare alternative estimators?

2.4Assessing the Least Squares

Fit

Page 50: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 50Chapter 2: The Simple Linear Regression Model

The estimator b2 can be rewritten as:

where

It could also be writen as:

2.4.1The Estimator b2

N

iii ywb

12

2)( xxxxw

i

ii

2 2β i ib w e

Eq. 2.10

Eq. 2.11

Eq. 2.12

2.4Assessing the Least Squares

Fit

Page 51: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 51Chapter 2: The Simple Linear Regression Model

We will show that if our model assumptions hold, then E(b2) = β2, which means that the estimator is unbiased. We can find the expected value of b2 using the fact that the expected value of a sum is the sum of the expected values:

using and

2.4.2The Expected

Values of b1 and b2

2 2 2 1 1 2 2

2 1 1 2 2

2

2

2

( ) ( ) (β ... )

(β ) ( ) ( ) ... ( )

(β ) ( )

β ( )

β

i i N N

N N

i i

i i

E b E b w e E w e w e w e

E E w e E w e E w e

E E w e

w E e

)()( iiii eEwewE 0)( ieE

Eq. 2.13

2.4Assessing the Least Squares

Fit

Page 52: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 52Chapter 2: The Simple Linear Regression Model

The property of unbiasedness is about the average values of b1 and b2 if many samples of the same size are drawn from the same population– If we took the averages of estimates from many

samples, these averages would approach the true parameter values b1 and b2

– Unbiasedness does not say that an estimate from any one sample is close to the true parameter value, and thus we cannot say that an estimate is unbiased

– We can say that the least squares estimation procedure (or the least squares estimator) is unbiased

2.4Assessing the Least Squares

Fit

2.4.2The Expected

Values of b1 and b2

Page 53: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 53Chapter 2: The Simple Linear Regression Model

2.4.3Repeated Sampling

Table 2.2 Estimates from 10 Samples2.4

Assessing the Least Squares

Fit

Page 54: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 54Chapter 2: The Simple Linear Regression Model

Figure 2.10 Two possible probability density functions for b2

The variance of b2 is defined as 2222 )]([)var( bEbEb

2.4Assessing the Least Squares

Fit

2.4.3Repeated Sampling

Page 55: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 55Chapter 2: The Simple Linear Regression Model

If the regression model assumptions SR1-SR5 are correct (assumption SR6 is not required), then the variances and covariance of b1 and b2 are:

2.4.4The Variances

and Covariances of b1 and b2

22

1 2var( ) σ i

i

xb

N x x

2

2 2

σvar( )i

bx x

2

1 2 2cov( , ) σi

xb bx x

Eq. 2.14

Eq. 2.15

Eq. 2.16

2.4Assessing the Least Squares

Fit

Page 56: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 56Chapter 2: The Simple Linear Regression Model

1. The larger the variance term σ2 , the greater the uncertainty there is in the statistical model, and the larger the variances and covariance of the least squares estimators.

2. The larger the sum of squares, , the smaller the variances of the least squares estimators and the more precisely we can estimate the unknown parameters.

3. The larger the sample size N, the smaller the variances and covariance of the least squares estimators.

4. The larger the term , the larger the variance of the least squares estimator b1.

5. The absolute magnitude of the covariance increases the larger in magnitude is the sample mean , and the covariance has a sign opposite to that of .

2xxi

2ix

xx

MAJOR POINTS ABOUT THE VARIANCES AND COVARIANCES OF b1 AND b2

2.4Assessing the Least Squares

Fit

2.4.4The Variances

and Covariances of b1 and b2

Page 57: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 57Chapter 2: The Simple Linear Regression Model

Figure 2.11 The influence of variation in the explanatory variable x on precision of estimation (a) Low x variation, low precision (b) High x variation, high precision

The variance of b2 is defined as 2222 )()var( bEbEb

2.4Assessing the Least Squares

Fit

2.4.4The Variances

and Covariances of b1 and b2

Page 58: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 58Chapter 2: The Simple Linear Regression Model

2.5 The Gauss-Markov Theorem

Page 59: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 59Chapter 2: The Simple Linear Regression Model

2.5The Gauss-

Markov Theorem

Under the assumptions SR1-SR5 of the linear

regression model, the estimators b1 and b2 have the

smallest variance of all linear and unbiased

estimators of b1 and b2. They are the Best Linear

Unbiased Estimators (BLUE) of b1 and b2

GAUSS-MARKOV THEOREM

Page 60: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 60Chapter 2: The Simple Linear Regression Model

MAJOR POINTS ABOUT THE GAUSS-MARKOV THEOREM

1. The estimators b1 and b2 are “best” when compared to similar estimators, those which are linear and unbiased. The Theorem does not say that b1 and b2 are the best of all possible estimators.

2. The estimators b1 and b2 are best within their class because they have the minimum variance. When comparing two linear and unbiased estimators, we always want to use the one with the smaller variance, since that estimation rule gives us the higher probability of obtaining an estimate that is close to the true parameter value.

3. In order for the Gauss-Markov Theorem to hold, assumptions SR1-SR5 must be true. If any of these assumptions are not true, then b1 and b2 are not the best linear unbiased estimators of β1 and β2.

2.5The Gauss-

Markov Theorem

Page 61: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 61Chapter 2: The Simple Linear Regression Model

4. The Gauss-Markov Theorem does not depend on the assumption of normality (assumption SR6).

5. In the simple linear regression model, if we want to use a linear and unbiased estimator, then we have to do no more searching. The estimators b1 and b2 are the ones to use. This explains why we are studying these estimators and why they are so widely used in research, not only in economics but in all social and physical sciences as well.

6. The Gauss-Markov theorem applies to the least squares estimators. It does not apply to the least squares estimates from a single sample.

2.5The Gauss-

Markov Theorem MAJOR POINTS ABOUT THE GAUSS-MARKOV THEOREM

Page 62: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 62Chapter 2: The Simple Linear Regression Model

2.6 The Probability Distributions of the

Least Squares Estimators

Page 63: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 63Chapter 2: The Simple Linear Regression Model

If we make the normality assumption (assumption SR6 about the error term) then the least squares estimators are normally distributed:

2.6The Probability Distributions of

the Least Squares

Estimators

2 2

1 1 2

σ~ β , i

i

xb N

N x x

2

2 2 2

σ~ β ,i

b Nx x

Eq. 2.17

Eq. 2.18

Page 64: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 64Chapter 2: The Simple Linear Regression Model

If assumptions SR1-SR5 hold, and if the sample

size N is sufficiently large, then the least squares

estimators have a distribution that approximates the

normal distributions shown in Eq. 2.17 and Eq. 2.18

2.6The Probability Distributions of

the Least Squares

Estimators

A CENTRAL LIMIT THEOREM

Page 65: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 65Chapter 2: The Simple Linear Regression Model

2.7 Estimating the Variance of the Error

Term

Page 66: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 66Chapter 2: The Simple Linear Regression Model

The variance of the random error ei is:

if the assumption E(ei) = 0 is correct.

Since the “expectation” is an average value we might consider estimating σ2 as the average of the squared errors:

where the error terms are

2.7Estimating the Variance of the

Error Term

2 2 2var( ) σ [ ( )] ( )i i i ie E e E e E e

22σ ie

N

1 2β βi i ie y x

Page 67: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 67Chapter 2: The Simple Linear Regression Model

The least squares residuals are obtained by replacing the unknown parameters by their least squares estimates:

There is a simple modification that produces an unbiased estimator, and that is:

so that:

1 2

22

ˆ ˆ

ˆσ

i i i i i

i

e y y y b b x

eN

22

Nei

2 2σ σE

Eq. 2.19

2.7Estimating the Variance of the

Error Term

Page 68: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 68Chapter 2: The Simple Linear Regression Model

Replace the unknown error variance σ2 in Eq. 2.14 – Eq. 2.16 by to obtain:

2.7.1Estimating the Variance and Covariance of

the Least Squares

Estimators

2

22

1 2ˆvar( ) σ i

i

xb

N x x

2

2 2

σvar( )i

bx x

21 2 2ˆcov( , ) σ

i

xb bx x

Eq. 2.20

Eq. 2.21

Eq. 2.22

2.7Estimating the Variance of the

Error Term

Page 69: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 69Chapter 2: The Simple Linear Regression Model

The square roots of the estimated variances are the “standard errors” of b1 and b2:

1 1se( ) var( )b bEq. 2.23

Eq. 2.24 2 2se( ) var( )b b

2.7Estimating the Variance of the

Error Term

2.7.1Estimating the Variance and Covariance of

the Least Squares

Estimators

Page 70: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 70Chapter 2: The Simple Linear Regression Model

2.7.2Calculations for

the Food Expenditure

Data

22 ˆ 304505.2σ 8013.29

2 38ie

N

Table 2.3 Least Squares Residuals2.7

Estimating the Variance of the

Error Term

Page 71: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 71Chapter 2: The Simple Linear Regression Model

The estimated variances and covariances for a regression are arrayed in a rectangular array, or matrix, with variances on the diagonal and covariances in the “off-diagonal” positions.

1 1 2

1 2 2

var( ) cov( , )

cov( , ) var( )

b b b

b b b

2.7Estimating the Variance of the

Error Term

2.7.2Calculations for

the Food Expenditure

Data

Page 72: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 72Chapter 2: The Simple Linear Regression Model

For the food expenditure data the estimated covariance matrix is:

2.7.2Calculations for

the Food Expenditure

Data

C IncomeC 1884.442 -85.90316

Income -85.90316 4.381752

2.7Estimating the Variance of the

Error Term

Page 73: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 73Chapter 2: The Simple Linear Regression Model

The standard errors of b1 and b2 are measures of the sampling variability of the least squares estimates b1 and b2 in repeated samples. – The estimators are random variables. As such,

they have probability distributions, means, and variances.

– In particular, if assumption SR6 holds, and the random error terms ei are normally distributed, then:

2.7.3Interpreting the Standard Errors

222 2 2~ β , var( ) σ ib N b x x

2.7Estimating the Variance of the

Error Term

Page 74: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 74Chapter 2: The Simple Linear Regression Model

The estimator variance, var(b2), or its square root, which we might call the true standard deviation of b2, measures the sampling variation of the estimates b2

– The bigger is the more variation in the least squares estimates b2 we see from sample to sample. If is large then the estimates might change a great deal from sample to sample

– If is small relative to the parameter b2,we know that the least squares estimate will fall near b2 with high probability

2 2σ varb b

2b

2b

2b

2.7Estimating the Variance of the

Error Term

2.7.3Interpreting the Standard Errors

Page 75: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 75Chapter 2: The Simple Linear Regression Model

The question we address with the standard error is ‘‘How much variation about their means do the estimates exhibit from sample to sample?’’

2.7Estimating the Variance of the

Error Term

2.7.3Interpreting the Standard Errors

Page 76: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 76Chapter 2: The Simple Linear Regression Model

We estimate σ2, and then estimate using:

– The standard error of b2 is thus an estimate of what the standard deviation of many estimates b2 would be in a very large number of samples, and is an indicator of the width of the pdf of b2

shown in Figure 2.12

2b

2 2

2

2

se( ) var( )

σ

i

b b

x x

2.7Estimating the Variance of the

Error Term

2.7.3Interpreting the Standard Errors

Page 77: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 77Chapter 2: The Simple Linear Regression Model

Figure 2.12 The probability density function of the least squares estimator b2.2.7

Estimating the Variance of the

Error Term

2.7.3Interpreting the Standard Errors

Page 78: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 78Chapter 2: The Simple Linear Regression Model

2.8Estimating Nonlinear Relationships

Page 79: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 79Chapter 2: The Simple Linear Regression Model

Economic variables are not always related by straight-line relationships; in fact, many economic relationships are represented by curved lines, and are said to display curvilinear forms.

Fortunately, the simple linear regression model y = β1 + β2 + eis much more flexible than it looks at first glance, because the variables y and x can be transformations, involving logarithms, squares, cubes or reciprocals, of the basic economic variables, or they can be indicator variables that take only the values zero and one.

Including these possibilities means the simple linear regression model can be used to account for nonlinear relationships between variables

2.8Estimating Nonlinear

RelationshipsTHE WORLD IS NOT LINEAR

Page 80: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 80Chapter 2: The Simple Linear Regression Model

Consider the linear model of house prices:

where SQFT is the square footage.– It may be reasonable to assume that larger and

more expensive homes have a higher value for an additional square foot of living area than smaller, less expensive, homes

1 2β βPRICE SQFT e Eq. 2.25

2.8Estimating Nonlinear

Relationships

Page 81: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 81Chapter 2: The Simple Linear Regression Model

We can build this into our model in two ways:1. a quadratic equation in which the explanatory

variable is SQFT2

2. a loglinear equation in which the dependent variable is ln(PRICE)

– In each case we will find that the slope of the relationship between PRICE and SQFT is not constant, but changes from point to point.

2.8Estimating Nonlinear

Relationships

Page 82: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 82Chapter 2: The Simple Linear Regression Model

The quadratic function y = β1 + β2x2 is a parabola– The elasticity, or the percentage change in y

given a 1% change in x, is:

2.8.1Quadratic Functions

ybx

yxslope22

2.8Estimating Nonlinear

Relationships

Page 83: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 83Chapter 2: The Simple Linear Regression Model

Figure 2.13 A quadratic function2.8

Estimating Nonlinear

Relationships

2.8.1Quadratic Functions

Page 84: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 84Chapter 2: The Simple Linear Regression Model

A quadratic model for house prices includes the squared value of SQFT, giving:

– The slope is:

– If , then larger houses will have larger slope, and a larger estimated price per additional square foot

2.8.2Using a

Quadratic Model

21 2α αPRICE SQFT e

2

ˆˆ2α

d PRICESQFT

dSQFT

Eq. 2.26

Eq. 2.27

2α 0

2.8Estimating Nonlinear

Relationships

Page 85: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 85Chapter 2: The Simple Linear Regression Model

Figure 2.14 A fitted quadratic relationship2.8

Estimating Nonlinear

Relationships

2.8.2Using a

Quadratic Model

Page 86: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 86Chapter 2: The Simple Linear Regression Model

For 1080 houses sold in Baton Rouge, LA during mid-2005, the estimated quadratic equation is:

– The estimated slope is:

– The elasticity is:

255776 56 0 0154PRICE . . SQFT

2

ˆ

ˆ2α

SQFTslopePRICE

SQFTSQFTPRICE

2 0 0154slope . SQFT

2.8Estimating Nonlinear

Relationships

2.8.2Using a

Quadratic Model

Page 87: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 87Chapter 2: The Simple Linear Regression Model

To compute an estimate we must select values for SQFT and PRICE– A common approach is to choose a point on the

fitted relationship • That is, we choose a value for SQFT and

choose for price the corresponding fitted value

2.8Estimating Nonlinear

Relationships

2.8.2Using a

Quadratic Model

Page 88: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 88Chapter 2: The Simple Linear Regression Model

For houses of 2000, 4000 and 6000 square feet, the estimated elasticities are:

respectively

For a 2000-square-foot house, we estimate that a 1% increase in house size will increase price by 1.05%

1.05 using1.63 using1.82 using

7$117,461.7CEIPR 9$302,517.3CEIPR

2$610,943.4CEIPR

2.8Estimating Nonlinear

Relationships

2.8.2Using a

Quadratic Model

Page 89: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 89Chapter 2: The Simple Linear Regression Model

The log-linear equation ln(y) = a + bx has a logarithmic term on the left-hand side of the equation and an untransformed (linear) variable on the right-hand side – Both its slope and elasticity change at each

point and are the same sign as b• The slope is:

– The elasticity, the percentage change in y given a 1% increase in x, at a point on this curve is:

2.8.3A Log-Linear

Function

bydxdy

bxyxslope

2.8Estimating Nonlinear

Relationships

Page 90: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 90Chapter 2: The Simple Linear Regression Model

Using the slope expression, we can solve for a semi-elasticity, which tells us the percentage change in y given a 1-unit increase in x:

100η 100

dy dxb

dx Eq. 2.28

2.8Estimating Nonlinear

Relationships

2.8.3A Log-Linear

Function

Page 91: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 91Chapter 2: The Simple Linear Regression Model

Consider again the model for the price of a house as a function of the square footage, but now written in semi-log form:

– This logarithmic transformation can regularize data that is skewed with a long tail to the right

2.8.4Using a Log-Linear Model

1 2ln γ γPRICE SQFT e Eq. 2.29

2.8Estimating Nonlinear

Relationships

Page 92: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 92Chapter 2: The Simple Linear Regression Model

Figure 2.16 (a) Histogram of PRICE (b) Histogram of ln(PRICE)2.8

Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 93: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 93Chapter 2: The Simple Linear Regression Model

Using the Baton Rouge data, the fitted log-linear model is:

– To obtain predicted price take the anti-logarithm, which is the exponential function:

ln 10.8386 0.0004113PRICE SQFT

exp ln exp 10.8386 0.0004113PRICE PRICE SQFT

2.8Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 94: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 94Chapter 2: The Simple Linear Regression Model

Figure 2.17 The fitted log-linear model2.8

Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 95: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 95Chapter 2: The Simple Linear Regression Model

The slope of the log-linear model is:

For a house with a predicted PRICE of $100,000, the estimated increase in PRICE for an additional square foot of house area is $41.13, and for a house with a predicted PRICE of $500,000, the estimated increase in PRICE for an additional square foot of house area is $205.63

2γ 0.0004113

d PRICEPRICE PRICE

dSQFT

2.8Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 96: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 96Chapter 2: The Simple Linear Regression Model

The estimated elasticity is:

– For a house with 2000-square-feet, the estimated elasticity is 0.823:• A 1% increase in house size is estimated to

increase selling price by 0.823%– For a house with 4000 square feet, the

estimated elasticity is 1.645: • A 1% increase in house size is estimated to

increase selling price by 1.645%

2ˆ γ 0.0004113SQFT SQFT

2.8Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 97: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 97Chapter 2: The Simple Linear Regression Model

Using the ‘‘semi-elasticity’’ defined in Eq. 2.28 we can say that, for a one-square-foot increase in size, we estimate a price increase of 0.04%– Or, perhaps more usefully, we estimate that a

100-square-foot increase will increase price by approximately 4%.

2.8Estimating Nonlinear

Relationships

2.8.4Using a Log-Linear Model

Page 98: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 98Chapter 2: The Simple Linear Regression Model

We should do our best to choose a functional form that is:– consistent with economic theory– that fits the data well– that is such that the assumptions of the

regression model are satisfied

2.8.5Choosing a

Functional Form

2.8Estimating Nonlinear

Relationships

Page 99: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 99Chapter 2: The Simple Linear Regression Model

In real-world problems it is sometimes difficult to achieve all these goals– Furthermore, we will never truly know the

correct functional relationship, no matter how many years we study econometrics

– The truth is out there, but we will never know it – In applications of econometrics we must simply

do the best we can to choose a satisfactory functional form

2.8Estimating Nonlinear

Relationships

2.8.5Choosing a

Functional Form

Page 100: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 100Chapter 2: The Simple Linear Regression Model

2.9Regression with Indicator Variables

Page 101: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 101Chapter 2: The Simple Linear Regression Model

An indicator variable is a binary variable that takes the values zero or one; it is used to represent a nonquantitative characteristic, such as gender, race, or location

– How do we model this?

2.9Regression with

Indicator Variables

OaksGolden in is house 0

Townity in Univers is house 1UTOWN

1 2β βPRICE UTOWN e

Page 102: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 102Chapter 2: The Simple Linear Regression Model

Figure 2.18 Distributions of house prices2.9

Regression with Indicator Variables

Page 103: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 103Chapter 2: The Simple Linear Regression Model

1 2

1

β β if 1β if 0

UTOWNE PRICE

UTOWN

1 2

215.7325 61.5091277.2416 if 1215.7325 if 0

PRICE b b UTOWNUTOWN

UTOWNUTOWN

2.9Regression with

Indicator Variables

When an indicator variable is used in a regression, it is important to write out the regression function for the different values of the indicator variable

– The estimated regression is:

1 2

1

β β if 1β if 0

UTOWNE PRICE

UTOWN

1 2

215.7325 61.5091277.2416 if 1215.7325 if 0

PRICE b b UTOWNUTOWN

UTOWNUTOWN

Page 104: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 104Chapter 2: The Simple Linear Regression Model

The least squares estimators b1 and b2 in this indicator variable regression can be shown to be:

– In the simple regression model, an indicator variable on the right-hand side gives us a way to estimate the differences between population means

OaksGolden Town University2

OaksGolden 1

PRICEPRICEb

PRICEb

2.9Regression with

Indicator Variables

Page 105: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 105Chapter 2: The Simple Linear Regression Model

Key Words

Page 106: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 106Chapter 2: The Simple Linear Regression Model

assumptions asymptotic B.L.U.E. biased estimator degrees of freedom dependent variable deviation from the

mean form econometric model economic model elasticity Gauss-Markov

Theorem heteroskedastic

homoskedastic independent

variable least squares

estimates least squares

estimators least squares

principle least squares

residuals linear estimator prediction random error term

regression model regression

parameters repeated sampling sampling precision sampling properties scatter diagram simple linear

regression function specification error unbiased estimator

Keywords

Page 107: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 107Chapter 2: The Simple Linear Regression Model

Appendices

Page 108: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 108Chapter 2: The Simple Linear Regression Model

2A Derivation of the Least Squares Estimates2B Deviation from the Mean Form of b2

2C b2 is a Linear Estimator2D Derivation of Theoretical Expression for b2

2E Deriving the Variance of b2

2F Proof of the Gauss-Markov Theorem

Page 109: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 109Chapter 2: The Simple Linear Regression Model

2ADerivation of the

Least Squares Estimates

Eq. 2A.1

Eq. 2A.2

21 2 1 2

1

1 21

22 1

2

(β ,β ) ( β β )

2 β 2 2 ββ

2 β 2 2 ββ

N

i ii

i i

i i i i

S y x

S N y x

S x x y x

Page 110: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 110Chapter 2: The Simple Linear Regression Model

Figure 2A.1 The sum of squares function and the minimizing values b1 and b2

2ADerivation of the

Least Squares Estimates

Page 111: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 111Chapter 2: The Simple Linear Regression Model

Eq. 2A.3

Eq. 2A.4

02

02

22

1

21

bxbxyx

bxNby

iiii

ii

Set the derivatives equal to zero to get two equations:

1 2

21 2

i i

i i i i

Nb x b y

x b x b x y

Simplify these to:

2ADerivation of the

Least Squares Estimates

Page 112: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 112Chapter 2: The Simple Linear Regression Model

Eq. 2A.5

Solving the two equations simultaneously, we get for b2:

222

ii

iiii

xxN

yxyxNb

2ADerivation of the

Least Squares Estimates

Page 113: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 113Chapter 2: The Simple Linear Regression Model

2BDeviation from the Mean Form

of b2

Eq. 2B.1

We can rewrite the equation 2A.5 by noting the following:

22

222

22

222

2

12

2

xNx

xNxNx

xNxN

Nxx

xNxxxxx

i

i

ii

iii

Also note that:

Nx

x

xxx

xNxxx

ii

ii

ii

22

2

222

Eq. 2B.2

Page 114: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 114Chapter 2: The Simple Linear Regression Model

Eq. 2B.3

Finally, we have:

Nyx

yx

yxNyxyyxx

iiii

iiii

2BDeviation from the Mean Form

of b2

Page 115: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 115Chapter 2: The Simple Linear Regression Model

We can rewrite b2 in deviation from the mean form as:

22 xx

yyxxb

i

ii

2BDeviation from the Mean Form

of b2

Page 116: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 116Chapter 2: The Simple Linear Regression Model

First note that we will always have:

0 xxi

2BDeviation from the Mean Form

of b2

Page 117: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 117Chapter 2: The Simple Linear Regression Model

Now rewrite our formula for b2 and use this fact:

ii

ii

i

i

ii

i

iii

i

ii

yw

yxx

xx

xxyxx

xxxxyyxx

xxyyxx

b

2

2

2

22

2Cb2 is a Linear

Estimator

Page 118: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 118Chapter 2: The Simple Linear Regression Model

2DDerivation of Theoretical

Expression for b2

To obtain Eq. 2.12, replace yi in Eq. 2.11 by yi = β1+ β2xi +ei and simplify:

2

1 2

1 2

2

β β

β β

β

i i

i i i

i i i i i

i i

b w y

w x e

w w x w e

w e

Page 119: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 119Chapter 2: The Simple Linear Regression Model

For this, we used the facts that:

2

2

2 2

1

0

1

β β

0

ii

i

i

i

i i

i i

i

x xw

x x

x xx x

w x

w x

x x

2DDerivation of Theoretical

Expression for b2

Page 120: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 120Chapter 2: The Simple Linear Regression Model

We can show that by using:

ii

iii

iii

xxx

xxxxxx

xxxxxx

2

so that:

1ii xw

1

2

ii

ii

i

iiii

xxxxxx

xxxxx

xw

2DDerivation of Theoretical

Expression for b2

Page 121: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 121Chapter 2: The Simple Linear Regression Model

2EDeriving the

Variance of b2

First note that:

2 2β i ib w e and that:

2222 )()var( bEbEb

Page 122: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 122Chapter 2: The Simple Linear Regression Model

2

2 2 2

2

2 2

2 2i

2 2

2

2

var( ) β β

2

E e 2

σ

σ

i i

i i

i i i j i ji j

i i j i ji j

i

i

b E w e

E w e

E w e w w e e

w w w E e e

w

x x

2EDeriving the

Variance of b2

Page 123: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 123Chapter 2: The Simple Linear Regression Model

2 22 2

222

2 2 22 2

2 2

σ var( ) ( ) 0

cov , 0

1

var( ) var( ) var( ) 2cov( , )

i i i i i

i j i i j j i j

iii

ii i

e E e E e E e E e

e e E e E e e E e E e e

x xx xw

x xx x x x

aX by a X b Y X Y

2EDeriving the

Variance of b2

Page 124: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 124Chapter 2: The Simple Linear Regression Model

2 2

2

2

2 2

2

2

var( ) var

var cov( , )

var( )

σ

σ

i i

i i i j i ji j

i i

i

i

b w e

w e w w e e

w e

w

x x

[since is a constant]2β

[generalizing the variance rule]

[using cov(ei,ej) = 0]

[using var(ei) = ]2

2EDeriving the

Variance of b2

Page 125: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 125Chapter 2: The Simple Linear Regression Model

2FProof of the

Gauss-Markov Theorem

To begin, let be any other linear estimator of β1. Also, suppose ki = wi + ci. Then:

ii ykb*2

*2 1 2

1 2

1 1 2 2

1 2 2

β β

β β

β β β β

β β β

i i i i i i i i i

i i i i i i i i

i i i i i i i i i

i i i i i i

b k y w c y w c x e

w c w c x w c e

w c w x c x w c e

c c x w c e

Eq. 2F.1

Page 126: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 126Chapter 2: The Simple Linear Regression Model

Now:

*2 1 2 2

1 2 2

*2 2

β β β

β β β

0 and 0

β

i i i i i i

i i i

i i i

i i i i i

E b c c x w c E e

c c x

c c x

b k y w c e

Eq. 2F.2

Eq. 2F.3

Eq. 2F.4

2FProof of the

Gauss-Markov Theorem

Page 127: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 127Chapter 2: The Simple Linear Regression Model

2 2 2

1 0i ii i i i i

i i i

c x x xc w c x cx x x x x x

For now, observe that :

Now we can write:

*2 2

2

22

2 2 2 2

2 22

2

var( ) var β

var

σ

σ σ

var σ

var

i i i

i i i

i i

i i

i

b w c e

w c e

w c

w c

b c

b

2FProof of the

Gauss-Markov Theorem

Page 128: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 128Chapter 2: The Simple Linear Regression Model

Monte Carlo simulation experiments use random number generators to replicate the random way that data are obtained– In Monte Carlo simulations we specify a data

generation process and create samples of artificial data• Then we ‘‘try out’’ estimation methods on the data

we have created– We create many samples of size N and examine the

repeated sampling properties of the estimators• In this way, we can study how statistical

procedures behave under ideal, as well as not so ideal, conditions

2GMonte Carlo Simulation

Page 129: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 129Chapter 2: The Simple Linear Regression Model

The data generation process for the simple linear regression model is given by:

– Each value of the dependent variable yi is obtained, or generated, by adding a random error ei to the regression function E(yi |xi )

– To simulate values of yi we create values for the systematic portion of the regression relationship E(yi |xi ) and add to it the random error ei

NiexbbexyEy

ii

iiii

,...,1

|

21

2GMonte Carlo Simulation

Page 130: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 130Chapter 2: The Simple Linear Regression Model

To create the variables for the regression function, we must:1. Select sample size N2. Choose xi values3. Choose β1 and β2

2G.1The Regression

Function

2GMonte Carlo Simulation

Page 131: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 131Chapter 2: The Simple Linear Regression Model

To be consistent with assumptions SR2–SR4 the random errors should have mean zero, a constant variance and be uncorrelated with one another–We can generate random numbers– Of course the computer-generated numbers

cannot be truly random, because they are generated by a computer code

– The random numbers created by computer software are ‘‘pseudorandom,’’ in that they behave like random numbers

2G.2The Random

Error

2GMonte Carlo Simulation

Page 132: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 132Chapter 2: The Simple Linear Regression Model

2G.3Theoretically True Values

Figure 2G.1 The true probability density functions of the data2G

Monte Carlo Simulation

Page 133: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 133Chapter 2: The Simple Linear Regression Model

Figure 2G.2 The true probability density functions of the estimator b2

2GMonte Carlo Simulation

2G.3Theoretically True Values

Page 134: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 134Chapter 2: The Simple Linear Regression Model

2G.4Creating a

Sample of Data

ˆ 75.7679 11.9683

se 25.7928 1.6313

ˆ σ 51.5857

i iy x

b1 b2

b1 665.2699 -39.9162

b2 -39.9162 2.6611

Variance-Covariance Matrix

2GMonte Carlo Simulation

Page 135: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 135Chapter 2: The Simple Linear Regression Model

What do we hope to achieve with a Monte Carlo experiment?–We would like to verify that under SR1–SR5 the

least squares estimators are unbiased–We would like to verify that under SR1–SR5 the

least squares estimators have sampling variances given by Eq. 2.14 and Eq. 2.16

–We would like to verify that the estimator of the error variance Eq. 2.19 is unbiased

– Because we have assumed the random errors are normal, SR6, we expect the least squares estimates to have a normal distribution.

2G.5Monte Carlo Objectives

2GMonte Carlo Simulation

Page 136: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 136Chapter 2: The Simple Linear Regression Model

2G.6Monte Carlo

Results

Table 2G.1 Summary of 1,000 Monte Carlo Samples2G

Monte Carlo Simulation

Page 137: Chapter 2 The Simple Linear Regression Model:  Specification and Estimation

Principles of Econometrics, 4th Edition Page 137Chapter 2: The Simple Linear Regression Model

Figure 2G.3 The sampling distribution of b2 in 1000 Monte Carlo samples2G

Monte Carlo Simulation

2G.6Monte Carlo

Results