


































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



































This chapter provides the standard results for least-square model fitting in the multiple linear regressions. In this chapter, we will talk, in a multiple regression model, about
A regression model that involves more than one regressor variable is called a multiple regression model. The general form of a regression model of independent variable is given by
k
= (^) β + β X + β X + + β Xk + ε k
where β 0 , (^) β 1 , L β k are the regression coefficients. The term linear is used because the
above equation is a linear function of the unknown parameters β 0 , (^) β 1 , L β k.
The parameter β j represents the expected change in the response Y per unit change in
X j when all of the remaining regressor variables^ X i (^ i ≠^ j )are held constant. For this
reason the parameters (^) β (^) j , j = 1 , 2 ,L k ,are often called partial regression coefficients.
Suppose, for each specific combination of independent variables (^) X 1 , (^) X 2 ,L , (^) Xk , the
variable is a random variable with certain probability distribution having finite mean and variance. In addition, we assume
μ (^) { Y | X 1 , X 2 ,L , Xk }=^ β 0 + β 1 X (^) 1 + β 2 X 2 +L+ β k Xk
Assumptions:
X (^) 1 ,^ X 2 ,L^ , Xk
1 2
Var Y X X Xk Y L k
The least-squares function is
( ) (^) ∑ (^) ⎟ ⎠
⎞ ⎜ ⎝
⎛ ∑ − − = =
n
i
n k i
k
j
S (^) i 1 yi jxij
2
1
2 0 1 2 1
β ,β ,β ,L,β ε β 0 β
The function S must be minimized with respect to β 0 , (^) β 1 , L β k. The least-squares
estimators of β 0 , (^) β 1 , L β k must satisfy the following equations:
and for j = 1 , 2 ,L, k ,
∂ β (^0)
β β β β
) ) ) ) L k
0 1 2
= − (^) ∑ ∑ = =
n
i
k i (^) j j ij y x 1 0 1
(^2) β β 0
) )
β (^) j
1 0 1
= − ∑ − −∑ = =
y (^) x xij
n
i
k
j i β^ β j ij
) )
β β β β
) ) ) ) L k
0 1 2
The least-squares normal equations are:
∑ ∑ ∑ ∑ = = = =
n
i i
n
i k ik
n
i i
n
i
n (^) xi x x y 1 1 1 2 2 1
β 0 β 1 1 β β
) ) ) ) L
∑ ∑ ∑ ∑ ∑ = = = = =
n
i i
n ki ik
n
i i
n
i
n
i
xi (^) xi xi x xi x xi y 1 2 1 2 1 1
2 β 0 1 1 β 1 1 β 1 β 1 1
) ) ) ) L
∑ ∑ ∑ ∑ ∑ = = = = =
n
i i
n ki ik
n
i i
n
i i
n
i
xi x x xi xi x xi y 1 1 1
2 β 0 1 2 β 1 1 2 1 β 2 2 β 2 2
) ) ) ) L
.....
i i ki i i i i ik i ik x (^) ik xik xiky (^21 ) 1 (^0111) β β β β
∑ + ∑ + ∑ + + ∑ = ∑
n n n n n x x x x
) ) ) ) 2 L = = = = =
ote that there are normal equations, one for each of the unknown regression lution to
N p = k + 1
coefficients. The so the normal equations will be the least-squares estimators
β β β β
) ) ) ) , , ,L,. 0 1 2 k
It is more convenient to deal with multiple regression models if they are expressed in matrix notation.
Example 1: Consider the following data:
y x 1 x 2 16 7 5 11 3 4 12 3 6 14 4 1
y
X ⎥
β
β
β
β
2
1
0 ,
⎥
ε
ε
ε
ε
ε
4
3
2
1
,
⎥
e
e
e
e
e
4
3
2
1
⎡ n^ n ⎤
∑
∑
∑
=
=
=
1 2
1 1
1 /
n
i i i
n
i i i
n
i i
x y
x y
y
X y
∑ ∑ ∑
∑ ∑ ∑
∑ ∑
= =
= = =
= =
1
2 2 1 1 2
2 1 1 1
2 1 1
1 1 1 2
/
n
i i i
n
i i
i
n
i i
n
i
n
i i
i i i i
x x x x
x x x x
x x
X X
i
i
n
( )
−
1 X^ X
Therefore,
( )
−
/ 1 / y β X X X
Y = 9. 41 + 1. (^11) X 1 − 0. (^22) X 2
y 1 =^9.^41 +^1.^11 (^7 )−^0.^22 (^5 )=^16.^08
) y 2 =^9.^41 +^1.^11 (^3 )−^0.^22 (^4 )=^11.^86
)
y 3 =^9.^41 +^1.^11 (^3 )−^0.^22 (^6 )=^11.^42
) y 4 =^9.^41 +^1.^11 (^4 )−^0.^22 (^1 )=^13.^63
)
Note that should be zero.
e y^ y
) ∑ =
n
i i e 1
( ) ( ) (^ )
( ) ( ) ( )⎥
Cov (^) Y 2 , Y 1 VarY 2 L CovY 2 , Yn
( ) ( ) ( ) ⎥
Y Y Y Y Y
Y Y Y Y Y
n n n
n
Cov Cov Var
Var Cov Cov
1 2
1 1 2 1
Properties of the Least-Squares Estimators:
Since the least-squares estimator β
) is a linear combination of the observations, it
follows that β
) is normally distributed with mean vector (^) β and covariance matrix
Cov Var ( (^) X /^ X ) 2 −^1 ⎟= ⎠
β β σ
) )
. This implies that the distribution β
) j
is normal
with mean β j and variance (^) σ C (^) ij where is the th diagonal element of the 2 C (^) ij j
( (^) X /^ X )
1 ma
− trix. Let
SE β (^) j MS (^) sCij σ Cij
) (^) ) ⎟= = ⎠
.. Re
Example 1 (cont.):
The estimate of the covariance matrix i
−
σ X^ X
)
s
( )^1.^219
.. ( ) 3. 4918 1. 868. .( ) 0. 1141 0. 3378 1 β =^ =
) S E , 0 β =^ =
) S E ,
.. ( ) 0. 0876 0. 2960 2 β =^ =
) S E
Gauss-Markov theorem states that the least-squares estimators are unbiased and have minimum variance when compared with all other unbiased estimators that are linear
combinations of the. Hence, the least-squares estimators are best linear unbiased
estimators , where “best” implies minimum variance.
ypothesis Testing:
The test statistic for testing
y (^) i
H (^) 0 :^ β^ j =^ β j 0 is
t S E j
⎝β
TS j^ j^0 ~ ⎛ ⎞
β β )
) )
-distribution, with df = n − p
Example 1 (cont.): The test statistic for testing (^) H 0 : (^) β 1 = 1 versus (^) H 1 : (^) β 1 > 1 is
( )
1
β
β )
)
= E
. Then df = 4 − 3 = 1
and
P − value = P ( TS > 0. 3256 )≅
T he test statistic for testing (^) H 0 : (^) β 2 = 0 versus (^) H 1 : (^) β 2 ≠ 0 is
( )
2
β
β )
)
TS. Then df = 4 − 3 = 1
and
P − value = 2 P ( TS > 0. 7432 )=
Analys ay use an analysis-of variance approach to test significance f regression. The analysis of variance is based on a partitioning of total variability in the esponse variabl.
is of Variance: We m o r e y
Squaring both sides of the above equation and summing over all observatio ns produces
= = =
i i i
1
2 1 1
L et
=
n
i
2
=
n
i
=
n
i
2 Re
The fundamental a alyn sis-of-variance identity for a regression model is
I t can be shown that
n
n
i i
n
n
i i i
n
i T
=
2
/
2
1
2
/ / / /
So n
n
i
2
/
Example 1 (cont.):
( )
( )
(^1611121453) 16 11 12 11
(^22) 2 2 2 14 = + + + − = − =
SST
( ) 1.^219
/ 1 1
(^22) Re =^ ∑^ − =∑ = = = = SS y y e e e
n
i
n
i s (^) i i i
)
SS (^) R =^ SST − SS Re s =^14.^75 −^1.^219 =^13.^531
df
SS MS R
R R ,^ 1 1.^219
Re
Re Re = = = df
SS MS s
s s
Re
MS
MS s
TS = F − test R , P − value = P ( TS > 5. 55 )
ource of ariation
Degrees of Freedom
Sum of Squares
Mean Square F-Value P-value
Regression p − (^1) SS (^) R MS (^) R
MS
MS s
R Re
Residual n^ −^ p SS Re s MS^ Re s
Total n − (^1) SS T MS^ T
Analysis of Variance
SAS Output:
Source DF Sum of Squares
Mean Square F Value Pr > F
Model 2 13.53094 6.76547 5.55 0.
Error 1 1.21906 1.
Corrected Total 3 14.
Root MSE 1.10411 R-Square 0.
Dependent Mean 13.25000 Adj R-Sq 0.
Coeff Var 8.
Parameter Estimates
Variable DF Parameter tim
Standard Err t Va ue Pr |t| Es ate or l >
Intercept 1 9.40635 1.86871 5.03 0.
x1 1 1.11371 0.33788 3.30 0.
x2 1 -0.22241 0.29607 -0.75 0.
Confidence Intervals:
A 100 ( 1 − α)percen t confid ence intervalfor β (^) j is
β (^) α β
) ) j t j
A 90% confidence interval for
/ 2 , df S^. E.
Example 1 (cont.): (^) β 1 is
. ( ) 0. 1141 0. 0876 0. 0082 ) 0. 2181 0. 4670 1 2 . (^) β −β = + − 2 ( − = =
) ) S E
A 90% c0nfidence interval for β β 1 2 − is
.. ( ) 1. 11 ( 0. 22 ) 6. 314 ( 0. 4670 ) ( 1. 6186 , 4. 2786 ) 1 2 /^2 , 1 2 β −β ± α β −β = − − ± ⇒^ −
) ) ) ) t (^) dfSE
orresponding to the point is
y 0
x
x
x x
0 k
02
01 0
c
( ) ⎟ ⎠
y (^) t df x X X x 0
2 /^1 0 /^2 ,
α^ σ^10
) )
E xample 1 (cont.): A 90% prediction interval for (^) y 0 for (^) x 1 = 4 and (^) x 2 = 5 is
Example 2: In the data set of the following table denotes the weight (in pounds) and e snout vent length (distance in inches from back of head to end of nose) for 15 lligators captured in central Florida. Because is easier to observe than for alligators el ing we to snout vent length. Such a model can be used to predict the weight of alligators with particular snout vent lengths. Fit a model to the data. Find a 90% prediction interval for
Alligator
w l th a l w in their natural habitat, we want to construct a mod relat ight
W if l = 54. 598.
l w 1 47.942 130. 2 36.966 50. 3 75.944 639. 4 30.877 27. 5 45.150 79. 6 46.063 109. 7 31.817 33. 8 42.948 90. 9 33.115 35. 10 35.874 38. 11 66.027 365. 12 43.816 83. 13 40.854 79. 14 41.679 83. 15 43.816 70.
Scat t er pl ot of Wei ght vs. Lengt h w
0
200
300
400
500
600
700
100
l
30 40 50 60 70 80