You are on page 1of 7

5.

(a)
model y=x1 x2 x3 / i;
X'X Inverse, Parameter Estimates, and SS
Variable
Intercept
x1
x2
x3
y
Intercept 8.0647946352 -0.082592705 -0.094195115 -0.790526876 39.481518388
x1
-0.082592705 0.0084798162 0.0017166872 0.0037200203
1.0092246002
x2
-0.094195115 0.0017166872 0.0166294243 -0.002063308 -1.872657152
x3
-0.790526876 0.0037200203 -0.002063308 0.0886012862 -0.36669973
y
39.481518388 1.0092246002 -1.872657152
-0.36669973 39.981263277

bo = 39.481518388
b1 = 1.0092246002
b2 = -1.872657152
b3 = -0.36669973
5.(b)
model y=x1 x2 x3 /

alpha = 0.05;
Analysis of Variance

Source

Sum of
Mean
DF
Squares
Square

F Value

Model
3
400.85104
133.61701
Error
9
39.98126
4.44236
Corrected Total 12
440.83231

30.08

Pr > F
<.0001

ANOVA table is as follows,


Source

Sum of Squares

df

Mean of Squares

Regression

400.85104

133.61701

Error

39.98126

4.44236

Total

440.83231

12

Hypothesis:
Ho: 1 = 2 = 3 = 0

H1: at least one of them is not zero

Decision rule:
Fobs = MSR/MSE
= 133.61701 / 4.44236
= 30.07793
F0.05,3,9 = 3.86 < Fobs and
p-value < 0.0001
Conclusion:
Ho is rejected at the 5% level of significance and there is a regression between Y and X1, X2
and X3 .

5.(c)
model y=x1 x2 x3 /

clb alpha = 0.01667;


Parameter Estimates

Variable DF

Parameter
Estimate

Standard
98.333% Confidence
Error
t Value Pr > |t|
Limits

Intercept 1
39.48152
5.98554 6.60 <.0001
21.92471
57.03832
x1
1
1.00922
0.19409 5.20 0.0006
0.43992
1.57853
x2
1
-1.87266
0.27180 -6.89 <.0001 -2.66989
-1.07542
x3
1
-0.36670
0.62737 -0.58 0.5732 -2.20692
1.47352

A 95% Bonferroni confidence interval estimates of 1 , 2 and 3 are:


(0.43992, 1.57853)
(-2.66989,1.07542)
(-2.20692,1.47352)
5.(d)
when (X1, X2, X3) = (3, 8, 9)
= 24.23
when (X1, X2, X3) = (5, 6, 7)
= 30.72
model y=x1 x2 x3 / i xpx alpha=0.01667;
output out=p p=p uclm=um lclm=lm;
run;
proc print noobs;
where y;

5.(e)
Hypothesis:
H0: 2 = 3 = 0

H1: at least one of them is not zero

Decision rule:
Using F-test,
model y=x1-x3;
test x2=0, x3=0;
Test 1 Results for Dependent Variable y
Source
Numerator
Denominator

DF
2
9

Square
107.47198
4.44236

F Value

Pr > F

24.19

0.0002

Fobs = 24.19
F0.05,2,9 = 4.26 < Fobs
and p-value = 0.0002 < 0.05
Conclusion:
H0 can be rejected at the 5% level of significance and not both X2 and X3 can be dropped
from the regression model.

5.(f)
Hypothesis:
H0: 1 = 1.0 and 2 = -2.0
Decision rule:

H1: H0 is false

model y=x1-x3;
test x1=1, x2=-2;
Test 1 Results for Dependent Variable y
Source
Numerator
Denominator

Mean
Square

DF

2
9

F Value

0.48850
4.44236

0.11

Pr > F
0.8971

Using F-test,
Fobs = 0.11
F0.05,2,9 = 4.26 > Fobs
and p-value = 0.8971 > 0.05
Conclusion:
Ho cannot be rejected at the 5% level of significance and 1 = 1.0 and 2 = -2.0 is true.
5.(g)
Suppose the entry level pin is 0.05
(i) Fit Y = o + jXj + for j = 1,2,3
model y=x1;
model y=x2;
model y=x3;

Additional variable

p-value
(Partial F-test for j = 0)

Partial F-value

X1

0.0163

8.02

X2

0.0014

17.93

X3

0.5357

0.41

X2 is added to the model as it has the smallest p-value and below the entry level
(ii) Fit Y = o + 2X2 + jXj + for j = 1,3
model y=x2 x1;
model y=x2 x3;

Additional variable

p-value
(Partial F-test for j = 0)

Partial F-value

X1

< 0.0001

48.11

X3

0.0063

8.77

X1 is added to the model as it has the smallest p-value and below the entry level

(iii)

Fit Y = o + 1X1 + 2X2 + 3X3 + for j = 1,3

model y=x1 x2 x3;

Additional variable

p-value
(Partial F-test for j = 0)

Partial F-value

X3

< 0.0001

30.08

X3 is added to the model as it has the smallest p-value and below the entry level
Therefore, the final selected model is
= 39.481518388 + 1.0092246002 X1 - 1.872657152 X2 0.36669973 X3
5.(h)
The full model is as same as the selected model in (g)
model y=x1 x2 x3 / clb;

Coeff Var

Root MSE
Dependent Mean
7.25443

2.10769 R-Square
0.9093
29.05385 Adj R-Sq
0.8791

R2 = 0.9093
Adjusted R2 = 0.8791
model y=x1 x2 x3/selection=cp;

Number in
Model
C(p)
2
3
1
2
1
2
1

Cp = 4.0

2.3416
4.0000
28.7339
29.0380
48.3851
49.4707
86.6785

R-Square Variables in Model


0.9059 x1 x2
0.9093 x1 x2 x3
0.6197 x2
0.6368 x2 x3
0.4217 x1
0.4309 x1 x3
0.0358 x3

10.(a)
model y=x/i xpx;
X'X Inverse, Parameter Estimates, and SSE
Variable

Intercept

Intercept
0.1697821037
-0.01437894
35.828510121
x
-0.01437894
0.0663643402
-21.05466209
y
35.828510121
-21.05466209
239.86170999

b0 = 35.828510121
b1 = -21.05466209
Fitted linear regression model:
= 35.828510121 21.05466209 X
10.(b)
Root MSE
7.74373 R-Square
Dependent Mean
31.26667 Adj R-Sq
Coeff Var
24.76674

0.9653
0.9567

R2 = 0.9653
As R2 is quite close to 1, an adequate linear relation appears.
10.(c)
Y
95.84
29.7
0.98
51.7
4.8
4.58

X
-2.5
0
2.1
-1
1.2
1.5

Predicted Y
88.46516535
35.82851012
-8.38628027
56.88317221
10.56291561
4.246516986

Residual
7.374834654
-6.12851012
9.366280268
-5.18317221
-5.76291561
0.333483014

The plot shows a lack of fit of the linear regression function. At the beginning, the residual is

positive for negative and small predicted Y. The residual becomes negative when predicted Y
increases to medium value. Finally, the residual is positive for large predicted Y.
10.(d)
model boxcox(y)=identity(x);

Box-Cox Transformation Information for y


Lambda

R-Square

0.00
0.25
0.50 +
0.75
1.00

0.91
0.97
0.99
0.99
0.97

Log Like

-11.8469
-8.7346
-5.2565 <
-7.5954
-12.2813

= 0, SSE = 0.91
= 0.5, SSE = 0.99
R2 when = 0.5 is higher that = 1 i.e. 0.99 > 0.91
A power value of = 0.5 is suggested
10.(e)
The fitted regression result of Y' on X is
= 35.828510121 21.05466209 X

Y
95.84
29.7
0.98
51.7
4.8
4.58

X
-2.5
0
2.1
-1
1.2
1.5

Predicted Y
2045.986535
357.7490445
10.19614392
866.8069924
39.45671217
9.754743614

Residual
-1950.147
-328.049
-9.216144
-815.107
-34.65671
-5.174744

The plot shows a linear relationship between residual and transformation of Y.


Residual is linearly related to
becomes constant.

and the rate of change of residual against predicted

You might also like