1
***********************************************************************;
2
***
SENIC hospital study
from Appendix C
of:
***;
3
***
Neter, J., Kutner,
M. H., Nachtsheim, C. J., and Wasserman, W., ***;
4
***
Applied Linear Statistical Models,
4th Edition, Richard D. ***;
5
***
Irwin, Inc., Burr
Ridge, Illinois,
1996.
***;
6
***********************************************************************;
7
OPTIONS
PS=256 LS=121 NOCENTER NODATE
NONUMBER;
8
9
DATA
SENIC; Infile cards
missover;
10
TITLE1
'SENIC database
from NKNW 1996 (Appendix C)';
11
INPUT IDNo LtofStay Age InfRisk CulRatio XRay NoBeds MedSch
Region
Census Nurses Services;
12
***
label IDNo = 'Identification number'
13
LtofStay =
'Length of stay (days)'
14
Age =
'Patient age (years)'
15
InfRisk = 'Average Infection risk
(%)'
16
CulRatio =
'ratio cultures to patients w/o symptoms'
17
XRay = 'ratio
xrays to patients w/o symptoms'
18
NoBeds = 'Average no. of beds
in hosp.'
19
MedSch = 'Med School
Affiliation'
20
Region = 'Region NE,
NC, S, W'
21
Census = 'Average no.
patients in hosp.'
22
Nurses = 'Av. no. nurses'
23
Services = '% of
35 potential service facilities';
24
CARDS;
NOTE:
The data set WORK.SENIC has 113 observations and
12 variables.
NOTE:
DATA statement used:
real time
0.30 seconds
cpu
time
0.12 seconds
24
!
Run;
138
;
139
Proc print
data=SENIC;
RUN;
NOTE:
There were 113 observations read from the data set WORK.SENIC.
NOTE:
The PROCEDURE PRINT printed page 1.
NOTE:
PROCEDURE PRINT used:
real time
0.26 seconds
cpu
time
0.09 seconds
SENIC database
from NKNW 1996 (Appendix C)
Ltof
Inf
Cul
No Med
Obs
IDNo
Stay Age
Risk
Ratio XRay
Beds
Sch Region
Census
Nurses Services
1
1 7.13
55.7
4.1 9.0
39.6
279 2
4
207 241
60.0
2
2 8.82
58.2 1.6
3.8 51.7
80
2
2
51
52 40.0
3
3 8.34
56.9
2.7 8.1
74.0
107 2
3
82 54
20.0
4
4 8.95
53.7
5.6 18.9
122.8
147 2
4
53 148 40.0
5
5 11.20
56.5
5.7 34.5
88.9
180 2
1
134 151
40.0
6
6 9.76
50.9
5.1 21.9
97.0
150 2
2
147 106
40.0
7
7 9.68
57.8
4.6 16.7
79.0
186 2
3
151 129
40.0
8
8 11.18
45.7
5.4 60.5
85.8
640 1
2
399 360
60.0
9
9 8.67
48.2
4.3 24.4
90.8
182 2
3
130 118
40.0
10
10 8.84
56.3
6.3 29.6
82.6
85 2
1
59 66
40.0
. . .
109
109
11.80 53.8
5.7
9.1 116.9
571
1
2 441
469 62.9
110
110
9.50 49.3
5.8
42.0 70.9
98
2
3
68 46
22.9
111
111
7.70 56.9
4.4
12.2 67.9
129
2
4
85
136 62.9
112
112
17.94 56.2
5.9
26.4 91.8
835
1
1 791
407 62.9
113
113 9.41
59.5 3.1
20.6
91.7 29
2
3
20 22
22.9
140
proc reg data=SENIC all LINEPRINTER;
141
TITLE2 'Full Model with
diagnostics';
142
model InfRisk = LtofStay Age
CulRatio XRay NoBeds Census Nurses Services
143
/ all influence collin
partial;
144
output out=next1 p=YHat r=e;
145
OPTIONS PS=50 LS=160; PLOT
RESIDUAL.*PREDICTED. / VREF=0;
146
OPTIONS PS=60 LS=120;
147
Run;
NOTE:
113 observations read.
NOTE:
113 observations used in computations.
148
OPTIONS PS=50 LS=130;
NOTE:
The data set WORK.NEXT1 has 113 observations and 14 variables.
NOTE:
The PROCEDURE REG printed pages 2-28.
NOTE:
PROCEDURE REG used:
real time
0.63 seconds
cpu
time
0.22 seconds
149
proc plot data=next1; PLOT e*YHat /
VREF=0;
150
run;
151
OPTIONS PS=256 LS=121;
152
NOTE:
There were 113 observations read from the data set WORK.NEXT1.
NOTE:
The PROCEDURE PLOT printed page 29.
NOTE:
PROCEDURE PLOT used:
real time
0.02 seconds
cpu
time
0.01 seconds
SENIC
database from NKNW 1996 (Appendix C)
Full
Model with diagnostics
The
REG Procedure
Descriptive
Statistics
Uncorrected
Standard
Variable
Sum
Mean
SS
Variance Deviation
Intercept
113.00000
1.00000
113.00000
0
0
LtofStay
1090.26000
9.64832
10928
3.65366 1.91146
Age
6015.20000
53.23186
322430
19.90594 4.46161
CulRatio
1784.60000
15.79292
39916
104.74924
10.23471
XRay
9224.00000
81.62832
794935
374.95776
19.36383
NoBeds
28495
252.16814
11350621
37188 192.84269
Census
21625
191.37168
6786317
23642 153.75956
Nurses
19577
173.24779
5563895
19395 139.26539
Services
4877.00000
43.15929
236367
231.06619
15.20086
InfRisk
492.10000
4.35487
2344.41000
1.79803
1.34091
Uncorrected Sums of Squares and Crossproducts
Variable
Intercept
LtofStay
Age
CulRatio
XRay
Intercept
113
1090.26
6015.2
1784.6
9224
LtofStay
1090.26
10928.3862
58217.008
17934.179
90581.657
Age
6015.2
58217.008
322429.74
93842.53
490828.22
CulRatio
1784.6
17934.179
93842.53
39915.96
155106.57
XRay
9224
90581.657
490828.22
155106.57
794934.88
NoBeds
28495
291825.09
1511173.4
480905.9
2345162.1
Census
21625
224243.93
1146930.4
366716.9
1786191.9
Nurses
19577
199032.96
1036347.9
340930
1621409.2
Services
4877
48211.858
259304.51
80247.9 401791.21
InfRisk
492.1
4901.071
26196.13
8631.16
41487.8
Uncorrected Sums of Squares and Crossproducts
Variable
NoBeds
Census
Nurses
Services
InfRisk
Intercept
28495
21625
19577
4877
492.1
LtofStay
291825.09
224243.93
199032.96
48211.858
4901.071
Age
1511173.4
1146930.4
1036347.9
259304.51
26196.13
CulRatio
480905.9
366716.9
340930
80247.9
8631.16
XRay
2345162.1
1786191.9
1621409.2
401791.21
41487.8
NoBeds
11350621
8710988
7690447
1490677.5
134511.4
Census
8710988
6786317
5923892
1136997.3
102981.5
Nurses
7690447
5923892
5563895
1030697.7
93495.4
Services
1490677.5
1136997.3
1030697.7
236367.28
22180.61
InfRisk
134511.4
102981.5
93495.4
22180.61
2344.41
SENIC
database from NKNW 1996 (Appendix C)
Full
Model with diagnostics
The
REG Procedure
Correlation
Variable
LtofStay
Age
CulRatio
XRay
NoBeds
LtofStay
1.0000
0.1889
0.3267
0.3825
0.4093
Age
0.1889
1.0000
-0.2258
-0.0189
-0.0588
CulRatio
0.3267
-0.2258
1.0000
0.4250
0.1397
XRay
0.3825
-0.0189
0.4250
1.0000
0.0458
NoBeds
0.4093
-0.0588
0.1397
0.0458
1.0000
Census
0.4739
-0.0548
0.1429
0.0629
0.9810
Nurses
0.3404
-0.0829
0.1989
0.0774
0.9155
Services
0.3555
-0.0405
0.1851
0.1119
0.7945
InfRisk
0.5334
0.0011
0.5592
0.4534
0.3598
Correlation
Variable
Census
Nurses
Services
InfRisk
LtofStay
0.4739
0.3404
0.3555
0.5334
Age
-0.0548
-0.0829
-0.0405
0.0011
CulRatio
0.1429
0.1989
0.1851
0.5592
XRay
0.0629
0.0774
0.1119
0.4534
NoBeds
0.9810
0.9155
0.7945
0.3598
Census
1.0000
0.9079
0.7781
0.3814
Nurses
0.9079
1.0000
0.7835
0.3940
Services
0.7781
0.7835
1.0000
0.4126
InfRisk
0.3814
0.3940
0.4126
1.0000
Model
Crossproducts
X'X X'Y Y'Y
Variable
Intercept
LtofStay
Age
CulRatio
XRay
Intercept
113
1090.26
6015.2
1784.6
9224
LtofStay
1090.26
10928.3862
58217.008
17934.179
90581.657
Age
6015.2
58217.008
322429.74
93842.53
490828.22
CulRatio
1784.6
17934.179
93842.53
39915.96
155106.57
XRay
9224
90581.657
490828.22
155106.57
794934.88
NoBeds
28495
291825.09
1511173.4
480905.9
2345162.1
Census
21625
224243.93
1146930.4
366716.9 1786191.9
Nurses
19577
199032.96
1036347.9
340930
1621409.2
Services
4877
48211.858
259304.51
80247.9
401791.21
InfRisk
492.1
4901.071
26196.13
8631.16
41487.8
Model Crossproducts X'X X'Y Y'Y
Variable
NoBeds
Census
Nurses
Services
InfRisk
Intercept
28495
21625
19577
4877
492.1
LtofStay
291825.09
224243.93
199032.96
48211.858
4901.071
Age
1511173.4
1146930.4
1036347.9
259304.51
26196.13
CulRatio
480905.9
366716.9
340930
80247.9
8631.16
XRay
2345162.1
1786191.9
1621409.2
401791.21
41487.8
NoBeds
11350621
8710988
7690447
1490677.5
134511.4
Census
8710988
6786317
5923892
1136997.3
102981.5
Nurses
7690447
5923892
5563895
1030697.7
93495.4
Services
1490677.5
1136997.3
1030697.7
236367.28
22180.61
InfRisk
134511.4
102981.5
93495.4
22180.61
2344.41
X'X
Inverse, Parameter Estimates, and SSE
Variable
Intercept
LtofStay
Age
CulRatio
XRay
Intercept
1.5858508096
-0.001322824 -0.025196942
-0.002266262
-0.001378744
LtofStay
-0.001322824
0.0051859266
-0.000559317
-0.000236511 -0.000125206
Age
-0.025196942
-0.000559317
0.0005385865
0.0000791345 3.7315905E-6
CulRatio
-0.002266262
-0.000236511
0.0000791345
0.0001256418 -0.000018668
XRay
-0.001378744
-0.000125206
3.7315905E-6
-0.000018668 0.0000327219
NoBeds
-0.000134192
0.0000554848
-5.086015E-6
-1.744267E-6 1.2384372E-7
Census
0.000244251
-0.000120582
0.0000114987
6.2102827E-6 1.3610934E-6
Nurses
9.3582332E-6
0.0000327339
-1.741494E-6
-3.965013E-6 -6.872235E-7
Services
-0.002065552
-0.00003638
-5.727461E-6
-4.319302E-6 -3.724035E-6
InfRisk
-0.747255248
0.1769313961
0.016213596
0.0469933765 0.0120368799
X'X
Inverse, Parameter Estimates, and SSE
Variable
NoBeds
Census
Nurses
Services
InfRisk
Intercept
-0.000134192
0.000244251
9.3582332E-6
-0.002065552 -0.747255248
LtofStay
0.0000554848
-0.000120582
0.0000327339
-0.00003638 0.1769313961
Age
-5.086015E-6
0.0000114987
-1.741494E-6
-5.727461E-6 0.016213596
CulRatio
-1.744267E-6
6.2102827E-6
-3.965013E-6
-4.319302E-6 0.0469933765
XRay
1.2384372E-7
1.3610934E-6
-6.872235E-7
-3.724035E-6 0.0120368799
NoBeds
7.9876579E-6
-8.96859E-6
-8.686793E-7
-6.032734E-6 -0.00144718
Census
-8.96859E-6
0.0000131054
-1.498917E-6 2.5756281E-6
0.0007279559
Nurses
-8.686793E-7
-1.498917E-6
3.3422233E-6
-4.330367E-6 0.001906211
Services
-6.032734E-6
2.5756281E-6
-4.330367E-6
0.0001128895 0.0162795745
InfRisk
-0.00144718
0.0007279559
0.001906211
0.0162795745 95.639819869
SENIC
database from NKNW 1996 (Appendix C)
Full
Model with diagnostics
The
REG Procedure
Model:
MODEL1
Dependent
Variable: InfRisk
Analysis
of Variance
Sum of
Mean
Source
DF
Squares
Square F Value
Pr > F
Model
8
105.74000
13.21750 14.37
<.0001
Error
104
95.63982 0.91961
Corrected
Total
112
201.37982
Root
MSE
0.95896 R-Square
0.5251
Dependent
Mean
4.35487 Adj R-Sq
0.4885
Coeff
Var
22.02053
Parameter Estimates
Squared
Parameter
Standard
Standardized Semi-partial
Variable
DF
Estimate
Error
t Value Pr > |t|
Type
I SS Type II SS
Estimate
Corr Type I
Intercept
1
-0.74726 1.20763
-0.62 0.5374
2143.03018
0.35211
0
.
LtofStay
1
0.17693 0.06906
2.56
0.0118 57.30511
6.03648
0.25221 0.28456
Age
1 0.01621
0.02226 0.73
0.4679
2.07506
0.48809
0.05395 0.01030
CulRatio
1
0.04699 0.01075
4.37
<.0001 31.45735
17.57678
0.35868 0.15621
XRay
1
0.01204 0.00549
2.19
0.0304
3.84765
4.42782
0.17382 0.01911
NoBeds
1
-0.00145 0.00271
-0.53 0.5945
6.51642
0.26220
-0.20813 0.03236
Census
1
0.00072796
0.00347 0.21
0.8343
0.17436
0.04044
0.08347 0.00086581
Nurses
1
0.00191 0.00175
1.09
0.2794
2.01642
1.08719
0.19798 0.01001
Services
1
0.01628 0.01019
1.60
0.1131
2.34765
2.34765
0.18455 0.01166
Parameter Estimates
Squared
Squared
Squared
Partial
Semi-partial
Partial
Variance
Variable
DF Corr
Type I
Corr Type II Corr Type II
Tolerance
Inflation 95%
Confidence Limits
Intercept
1
.
.
.
.
0
-3.14203 1.64752
LtofStay
1
0.28456
0.02998
0.05937
0.47122
2.12214
0.03999 0.31388
Age
1
0.01440
0.00242
0.00508
0.83281
1.20076
-0.02792
0.06035
CulRatio
1
0.22153
0.08728
0.15525
0.67842
1.47402
0.02568 0.06831
XRay
1
0.03481
0.02199
0.04425
0.72772
1.37416
0.00116 0.02291
NoBeds
1
0.06108
0.00130
0.00273
0.03006
33.26931
-0.00682 0.00393
Census
1
0.00174 0.00020079
0.00042261
0.02882
34.70183
-0.00616
0.00761
Nurses
1
0.02016
0.00540
0.01124
0.13774
7.26005
-0.00157
0.00538
Services
1
0.02396
0.01166
0.02396
0.34229
2.92151
-0.00393
0.03648
Covariance of Estimates
Variable
Intercept
LtofStay
Age
CulRatio
XRay
Intercept
1.4583700555
-0.001216487
-0.023171451
-0.002084085 -0.001267912
LtofStay
-0.001216487
0.0047690489
-0.000514356
-0.000217498 -0.000115141
Age
-0.023171451 -0.000514356
0.0004952915
0.0000727731 3.4316216E-6
CulRatio
-0.002084085
-0.000217498
0.0000727731
0.0001155419 -0.000017167
XRay
-0.001267912
-0.000115141
3.4316216E-6
-0.000017167 0.0000300915
NoBeds
-0.000123405
0.0000510246
-4.677169E-6
-1.604051E-6 1.1388838E-7
Census
0.0002246165
-0.000110889
0.0000105743
5.7110607E-6 1.2516801E-6
Nurses
8.6059591E-6
0.0000301025
-1.601502E-6
-3.64628E-6 -6.319801E-7
Services
-0.00189951
-0.000033456
-5.267051E-6
-3.972089E-6 -3.424674E-6
Covariance of
Estimates
Variable
NoBeds
Census
Nurses
Services
Intercept
-0.000123405
0.0002246165
8.6059591E-6 -0.00189951
LtofStay
0.0000510246
-0.000110889
0.0000301025 -0.000033456
Covariance
of Estimates
Variable
NoBeds
Census
Nurses
Services
Age
-4.677169E-6
0.0000105743
-1.601502E-6 -5.267051E-6
CulRatio
-1.604051E-6
5.7110607E-6
-3.64628E-6 -3.972089E-6
XRay
1.1388838E-7
1.2516801E-6
-6.319801E-7 -3.424674E-6
NoBeds
7.3455592E-6
-8.247638E-6
-7.988493E-7 -5.547785E-6
Census
-8.247638E-6
0.0000120519
-1.378425E-6 2.3685827E-6
Nurses
-7.988493E-7
-1.378425E-6 3.0735542E-6
-3.982265E-6
Services
-5.547785E-6
2.3685827E-6
-3.982265E-6 0.0001038147
SENIC
database from NKNW 1996 (Appendix C)
Full
Model with diagnostics
The
REG Procedure
Model:
MODEL1
Dependent
Variable: InfRisk
Correlation
of Estimates
Variable
Intercept
LtofStay
Age
CulRatio
XRay
Intercept
1.0000
-0.0146
-0.8622
-0.1606
-0.1914
LtofStay
-0.0146
1.0000
-0.3347
-0.2930
-0.3039
Age
-0.8622
-0.3347
1.0000
0.3042
0.0281
CulRatio
-0.1606
-0.2930
0.3042
1.0000
-0.2911
XRay
-0.1914
-0.3039
0.0281
-0.2911
1.0000
NoBeds
-0.0377
0.2726
-0.0775
-0.0551
0.0077
Census
0.0536
-0.4625
0.1369
0.1530
0.0657
Nurses
0.0041
0.2486
-0.0410
-0.1935
-0.0657
Services
-0.1544
-0.0475
-0.0232
-0.0363
-0.0613
Correlation of
Estimates
Variable
NoBeds
Census
Nurses
Services
Intercept
-0.0377
0.0536
0.0041
-0.1544
LtofStay
0.2726
-0.4625
0.2486
-0.0475
Age
-0.0775
0.1369
-0.0410
-0.0232
CulRatio
-0.0551
0.1530
-0.1935
-0.0363
XRay
0.0077
0.0657
-0.0657
-0.0613
NoBeds
1.0000
-0.8766
-0.1681
-0.2009
Census
-0.8766
1.0000
-0.2265
0.0670
Nurses
-0.1681
-0.2265
1.0000
-0.2229
Services
-0.2009
0.0670
-0.2229
1.0000
Sequential
Parameter Estimates
Intercept
LtofStay
Age
CulRatio
XRay
4.354867
0
0
0
0
0.744304
0.374217
0
0
0
2.265909
0.387916
-0.031067
0
0
0.397766
0.269740
0.008351
0.057623
0
-0.083236
0.239464
0.008050
0.050572
0.011031
-0.424573
0.169755
0.017327
0.050376
0.013107
-0.393711
0.157208
0.018602
0.050908
0.013235
-0.449386
0.182178
0.017040
0.047616
0.012574
-0.747255
0.176931
0.016214
0.046993
0.012037
Sequential Parameter
Estimates
NoBeds
Census
Nurses
Services
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0.001403
0
0
0
0.000299
0.001472
0
0
-0.000577
0.000357
0.002531
0
-0.001447
0.000728
0.001906
0.016280
Collinearity Diagnostics
Condition -----------------------------Proportion
of
Variation-----------------------------
Number
Eigenvalue
Index Intercept
LtofStay
Age
CulRatio
XRay NoBeds
1
7.92221
1.00000 0.00008203
0.00026608
0.00008384
0.00241 0.00055647
0.00014889
2
0.70667 3.34824
0.00062369
0.00113
0.00066774
0.02105
0.00504 0.00316
3
0.23449
5.81248
0.00150
0.00158
0.00222 0.67694
0.00076682
0.00000481
4
0.04727 12.94588
0.00082735
0.04556
0.00039099
0.00635
0.00030739
0.02079
5
0.03554 14.93049
0.00123
0.00104
0.00130
0.09639
0.43090 0.00276
6
0.02878
16.59008
0.01898
0.01720
0.02926
0.06172 0.48518
0.00092814
7
0.01657
21.86586 0.03592
0.60385
0.02075
0.05279
0.05646 0.10941
8
0.00546
38.09407
0.03300
0.27836
0.00195
0.01730
0.00245 0.85653
9
0.00301
51.29072
0.90784 0.05102
0.94338
0.06505
0.01834 0.00627
Number
Census
Nurses Services
1 0.00014895
0.00070822
0.00057691
2
0.00351
0.01543 0.00004055
3 8.741457E-8
0.00219 0.00244
4
0.05162
0.47665 0.11157
5
0.00000597
0.22472 0.43144
6
0.00018174
0.13803 0.36303
7
0.00117
0.13349 0.06932
8
0.93113
0.00712 0.01485
9
0.01224
0.00166 0.00673
SENIC database
from NKNW 1996 (Appendix C)
Full Model
with
diagnostics
The REG
Procedure
Model: MODEL1
Dependent
Variable: InfRisk
Output Statistics
Dep Var
Predicted Std
Error
Std Error
Obs InfRisk
Value Mean Predict 95%
CL
Mean 95%
CL Predict Residual
Residual
1 4.1000
3.5001 0.3025
2.9002
4.0999 1.5060
5.4941
0.5999 0.910
2 1.6000
3.2294 0.2303
2.7727
3.6862 1.2737 5.1852
-1.6294 0.931
3 2.7000
3.2557 0.2019
2.8553
3.6560 1.3123 5.1990
-0.5557 0.937
4 5.6000
4.8324 0.3086
4.2204
5.4444 2.8347
6.8301
0.7676 0.908
5 5.7000
5