Y = β β x y x
Y = β β x y x
MS AMS
AMS 532 General Linear Models
11.4 Auditors are often required to compare the audited (or current) value of an inventory item with book (or
listed) value. If a company is keeping its inventory and books up to date, there should be a strong linear
relationship between the audited and book values. A company sampled ten inventory items and obtained the
audited and book values given in the accompanying table. Fit the model Y = β0 + β 1 x to these data.
yi xi xi yi x i2
9 10 90 100
14 12 168 144
7 9 63 81
29 27 783 729
45 47 2115 2209
109 112 12208 12544
40 36 1440 1296
238 241 57358 58081
60 59 3540 3481
170 167 28390 27889
n n n n
Answer:
yi xi xi yi x i2
27.6 1 27.6 1
32.5 2 65 4
35.9 3 107.7 9
39.3 4 157.2 16
44.2 5 221 25
48.8 6 292.8 36
55.7 7 389.9 49
62.9 8 503.2 64
n n n n
symmetrically spaced about zero.) Compute SSEand compare your answer to the result of part (a).
Answer:
yi xi xi yi x i2 y i2
27.6 1 27.6 1 761.76
32.5 2 65 4 1056.25
35.9 3 107.7 9 1288.81
39.3 4 157.2 16 1544.49
44.2 5 221 25 1953.64
48.8 6 292.8 36 2381.44
55.7 7 389.9 49 3102.49
62.9 8 503.2 64 3956.41
n n n n n
a.
n n n 2
1
S yy =∑ ( y i− ý ) 2=∑ y i2−
i=1 i=1 n ( )
∑ yi
i=1
1
S yy =16045.29− ( 346.9 )2 =16045.29−15042.45125=1002.8388
8
^
β 1=4. 84166 … 4.842 and S xy =20 3 .35
SSE=S yy− ^ β 1 S xy=1002.8388−( 4.84166 ) ( 203.35 )=1002.8388−984.5516=18.286
SSE 18.286
S2 = = =3.04 787
n−2 8−2
b.
yi y i2 x i¿ x ¿i y i x ¿2
i
27.6 761.76 -7 -193.2 49
32.5 1056.25 -5 -162.5 25
35.9 1288.81 -3 -107.7 9
39.3 1544.49 -1 -39.3 1
44.2 1953.64 1 44.2 1
48.8 2381.44 3 146.4 9
55.7 3102.49 5 278.5 25
62.9 3956.41 7 440.3 49
n n n n n
2 ¿ ¿
∑ yi =346.9 ∑ y i =16045.29 ∑ x i =0 ∑ x i y i=406.7 ∑ x ¿2
i =168
i=1 i=1 i=1 i=1 i =1
n
1 1
x́ ¿=∑
n i=1
n
x ¿i=
8 ()
( 0 )=0
1 1
ý= ∑ y i=
n i=1
n
8 ()
(346.9 )=43.3625
n n n
1
S x y =∑ ( x ¿i − x́¿ ) ( y i− ý )=∑ x ¿i y i−
¿
∑ x ¿i ∑ y i
i =1 i=1 n i=1 i=1
1
S x y =406.7− ( 0 ) ( 346.9 )=406.7−0=406.7
¿
8
n n n 2
1 2
S x x =∑ ( x − x́ ) =∑ x − ∑ x ¿i
¿ ¿
i=1 i=1
¿
i
¿
n i=1
¿2
i ( )
1
S x x =168− ( 0 )2=168−0=16 8
¿ ¿
8
S 406.7
β 1= x y =
¿
^ =2.42
Sx x 168
¿ ¿
^
β 0= ý − ^β1 x́ ¿=43.3625−( 2.42 ) ( 0 ) =43.3625−0=43.3625
n n n 2
1
S yy =∑ ( y i− ý ) 2=∑ y i2−
i=1 i=1 n ( )
∑ yi
i=1
1
S yy =16045.29− ( 346.9 )2 =16045.29−15042.45125=1002.8388
8
^
β 1=2.420833 2.42 and S xy =406.7
SSE=S yy − ^β 1 S x y =1002.8388−( 2.420833 ) ( 406.7 ) =1002.8388−984.5527=18.286
¿
SSE 18.286
S2 = = =3.04 787
n−2 8−2
Answer:
a.
Toxicant LC50 Flow-Through ( y ) LC50 Static ( x )
1 23.00 39.00
2 22.30 37.50
3 9.40 22.20
4 9.70 17.50
5 .15 .64
6 .28 .45
7 .75 2.62
8 .51 2.63
9 28.00 32.00
10 .39 .77
yi xi xi yi x i2 y i2
23.00 39.00 897 1521 529
22.30 37.50 836.25 1406.25 497.29
9.40 22.20 208.68 492.84 88.36
9.70 17.50 169.75 306.25 94.09
.15 .64 0.096 0.4096 0.0225
.28 .45 0.126 0.2025 0.0784
.75 2.62 1.965 6.8644 0.5625
.51 2.36 1.3413 6.9169 0.2601
28.00 32.00 896 1024 784
.39 .77 0.1463 0.5929 0.1521
n n n n n
yi x i¿ x i¿ y i x i¿2 y i2
23.00 23.496 540.408 552.062016 529
22.30 21.996 490.5108 483.824016 497.29
9.40 6.696 62.9424 44.836416 88.36
9.70 1.996 19.3612 3.984016 94.09
.15 -14.864 -2.2296 220.938496 0.0225
.28 -15.054 -4.21512 226.622916 0.0784
.75 -12.884 -9.663 165.997456 0.5625
.51 -13.144 -6.70344 172.764736 0.2601
28.00 16.496 461.888 272.118016 784
.39 -14.734 -5.74626 217.090756 0.1521
n n n n n
2 ¿ ¿
∑ yi =94.48 ∑ y i =1993.816 ∑ x i =0 ∑ x i y i=1546. 459 ∑ x ¿2
i =2360.239
i=1 i=1 i=1 i=1 i=1
n
1 1
x́ ¿=∑
n i=1
n
x ¿i=
10 ( )
( 0 )=0
1 1
ý= ∑ y i=
n i=1
n
10 ( )
( 94.48 )=9.448
n n n
1
S x y =∑ ( x ¿i − x́¿ ) ( y i− ý )=∑ x ¿i y i−
¿
∑ x ¿i ∑ y i
i =1 i=1 n i=1 i=1
1
S x y =1546.459− ( 0 ) ( 94.48 )=1546.459−0=1546.459
¿
10
n n n 2
2 1
S x x =∑ ( x − x́ ) =∑ x − ∑ x ¿i
¿ ¿
i=1
¿
i
¿
i=1 n i=1
¿2
i ( )
1
S x x =2360.239− ( 0 )2=2360.239−0=2360.239
¿ ¿
10
S 1546.459
β 1= x y =
¿
^ =0.655
S x x 2360.239
¿ ¿
^
β 0= ý − ^β1 x́ ¿=9.448−( 0.655 ) ( 0 ) =9.448−0=9.448
n n n 2
1
S yy =∑ ( y i− ý ) 2=∑ y i2−
i=1 i=1 n ( )
∑ yi
i=1
1
S yy =1993.816− ( 94.48 )2=1993.816−892.647=1 101.1686
10
β 1=0.6552528 … 0.655 and S x y =1546.459
^ ¿
SSE 87.8473
S2 = = =10.98091 10.98
n−2 10−2