0% found this document useful (0 votes)
32 views8 pages

Lecture 2 - Mulitple Linear Regression

The document presents a lecture on Multiple Linear Regression, detailing the process of determining the regression equation using matrix operations and predicting values based on given inputs. It includes an example problem with data points, calculations for the regression coefficients, and hypothesis testing to assess the significance of the regressor variables. The final results indicate that at least one regressor variable is significant in predicting the dependent variable Y.

Uploaded by

ann04114
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views8 pages

Lecture 2 - Mulitple Linear Regression

The document presents a lecture on Multiple Linear Regression, detailing the process of determining the regression equation using matrix operations and predicting values based on given inputs. It includes an example problem with data points, calculations for the regression coefficients, and hypothesis testing to assess the significance of the regressor variables. The final results indicate that at least one regressor variable is significant in predicting the dependent variable Y.

Uploaded by

ann04114
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Lecture 2: Multiple Linear Regression

Example Problem 1: Y X1 X2
Using the following data,
1 270 80 35
a. Determine the equation of the line using matrix. 2 120 30 20
b. Predict value of Y when X1 = 75 and X2 = 40
3 250 35 30
c. Perform hypothesis testing and ANOVA to determine the significance
of the regressor variables. 4 200 40 50
5 160 25 50
6 228 35 70
Solution: 7 180 25 35
8 140 80 85
a. Determine the equation of the line using matrix.

270 1 80 35
120 1 30 20
250 1 35 30 𝑏0 1 1 1 1 1 1 1 1
200 1 40 50
y= x= B = [𝑏1 ] XT = [80 30 35 40 25 35 25 80]
160 1 25 50
𝑏2 35 20 30 50 50 70 35 85
228 1 35 70
180 1 25 35
[140] [1 80 85]

Steps:
1. Solve for A = XT X

1 80 35
1 30 20
1 1 1 1 1 1 1 1 1 35 30 8 350 375
1 40 50
A = [80 30 35 40 25 35 25 80] x = [350 19000 17825 ]
1 25 50
35 20 30 50 50 70 35 85 375 17825 20875
1 35 70
1 25 35
[1 80 85]
2. Solve for g = XT y

270
120
1 1 1 1 1 1 1 1 250 1548
200
g = [80 30 35 40 25 35 25 80] x = [69630]
160
35 20 30 50 50 70 35 85 71510
228
180
[140 ]

3. Solve for g = AB

8 350 375 𝑏0 8𝑏0 + 350𝑏1 + 375𝑏2


AB = [350 19000 17825] x [𝑏1 ] = [350𝑏0 + 19000𝑏1 + 17825𝑏2 ]
375 17825 20875 𝑏2 375𝑏0 + 17825𝑏1 + 20875𝑏2

4. Equate: AB = XT y

8𝑏0 + 350𝑏1 + 375𝑏2 1548


[350𝑏0 + 19000𝑏1 + 17825𝑏2 ] = [69630]
375𝑏0 + 17825𝑏1 + 20875𝑏2 71510

which leads to three equations of three unknowns as shown in the next solution (elimination technique).
Using Variable Elimination Technique to get the Unknown Variables:

Thus, the equation of the line is Y = 190.3961 + 0.7663 X1 – 0.6490 X2

b. Predict value of Y when X1 = 75 and X2 = 40


Y = 190.3961 + 0.7663 (75) – 0.6490 (40)
Y = 221.9086
c. Perform hypothesis testing and ANOVA to determine the significance of the regressor variables.
Hypothesis Testing:
H0: β1 = β2 (the regressor variable/s is/are not significant)
H1: β1 ≠ β2 (the regressor variable/s is/are significant)
α = 0.05

F-critical (Ftab): fα, v1, v2 = fo.05, 2, 7 = 4.74


Since 13.7865 > 4.74, Reject H0. The regression coefficient differs from a constant. That is, at least one regressor variable is important.
(Example: If B1 ≠ 0, then X1 is needed in the equation of Y to predict future values.)

Example Problem 2:

Suppose in Review Exercise 11.53 on page 437 that we were also given the number of class periods missed by the 12 students taking the chemistry course. The complete data are shown.

You might also like