BRIEF ANSWERS TO PRACTICE PROBLEMS: SAS code given below! Practice Problem 1 ------------------- (a) The estimated slope is 0.264. We estimate that the mean circumference of a tree will increase by 0.264 inches for each one-ring increase in the number of rings, holding SIDE constant. (b) The adjusted sample mean circumference for the north side is 18.94 inches, and the adjusted sample mean for the south side is 35.97 inches. (c) Based on the P-value for the interaction term, the equal-slopes model is NOT sufficient. The equal-slopes assumption is rejected (P-value = .0086). Practice Problem 2 ------------------- (a) See page 536 for the form of the logistic regression model. (b) See SAS code for model fitting. Note beta_0_hat = -4.048 and beta_1_hat = 0.057. (c) Hosmer-Lemeshow test has a P-value of 0.5403, so we conclude the logistic model is appropriate. (d) The Wald test about beta_1 has a P-value of 0.0149, so at alpha = .05, we conclude ventricle size has a significant effect on the probability of abnormal brain wave behavior. (e) The estimated odds ratio is 1.059, so we estimate that the odds of having an abnormal brain wave reading increases by 105.9% (by a factor of 1.059) when the ventricle size increases by one unit. (f) Since the estimate of beta_1 is positive, a person with a smaller venticle size is estimated to have a lesser probability of abnormal brain wave behavior than a person with a larger ventricle size. (g) Run the SAS code below to see the plot (it is a monotone increasing curve). /* ************ SAS code *************************** */ data trees; input OBS SIDE $ RINGS CIRCUM; cards; 1 NORTH 93 33.00 2 NORTH 164 51.50 3 NORTH 138 43.10 4 NORTH 125 23.25 5 NORTH 129 24.50 6 NORTH 65 18.75 7 NORTH 193 43.50 8 NORTH 68 12.00 9 NORTH 139 31.75 10 NORTH 81 20.40 11 NORTH 73 16.00 12 NORTH 130 25.50 13 NORTH 147 44.00 14 NORTH 51 9.20 15 NORTH 56 15.40 16 NORTH 61 6.75 17 NORTH 115 11.40 18 NORTH 70 24.75 19 NORTH 44 8.25 20 NORTH 44 9.80 21 NORTH 63 14.30 22 NORTH 133 31.50 23 NORTH 239 41.50 24 NORTH 133 24.50 25 SOUTH 35 20.00 26 SOUTH 30 25.00 27 SOUTH 42 35.00 28 SOUTH 30 17.50 29 SOUTH 21 18.00 30 SOUTH 79 30.25 31 SOUTH 60 28.50 32 SOUTH 63 19.50 33 SOUTH 53 28.00 34 SOUTH 131 52.00 35 SOUTH 155 61.50 36 SOUTH 34 27.25 37 SOUTH 58 23.75 38 SOUTH 55 13.00 39 SOUTH 105 39.25 40 SOUTH 66 24.40 41 SOUTH 70 29.00 42 SOUTH 56 26.25 43 SOUTH 38 10.90 44 SOUTH 43 22.50 45 SOUTH 47 33.25 46 SOUTH 157 65.25 47 SOUTH 100 51.50 48 SOUTH 22 15.60 49 SOUTH 105 52.00 ; run; PROC GLM data=trees; CLASS SIDE; MODEL CIRCUM = SIDE RINGS / SOLUTION; LSMEANS SIDE / STDERR PDIFF; RUN; PROC GLM data=trees; CLASS SIDE; MODEL CIRCUM = SIDE RINGS SIDE*RINGS / SOLUTION; LSMEANS SIDE / STDERR PDIFF; RUN; data brain; input VENT EEG; cards; 53 0 37 0 63 0 25 0 60 0 58 0 56 0 59 0 50 0 58 1 70 0 68 1 50 0 59 0 51 0 76 0 74 1 62 1 41 0 65 0 50 0 94 1 73 1 72 0 45 1 56 0 56 0 75 0 76 0 78 1 50 0 68 0 47 0 66 0 42 1 76 1 57 0 65 0 51 0 83 1 51 0 80 1 70 0 68 1 49 0 56 1 58 1 58 1 64 1 60 1 57 0 54 0 58 0 63 1 61 0 70 0 40 0 51 1 58 1 70 1 57 1 84 0 58 0 51 1 57 0 85 1 50 0 48 0 67 1 62 0 65 0 ; run; PROC LOGISTIC DESCENDING DATA=brain; MODEL EEG = VENT / LACKFIT; OUTPUT OUT=NEW P=PRED L=LOWER U=UPPER; RUN; PROC SORT DATA=NEW; BY VENT; symbol1 i = join v=circle l=32 c = black; symbol2 i = join v=star l=32 c = black; symbol3 i = join v=star l=32 c = black; PROC GPLOT DATA=NEW; PLOT PRED*VENT LOWER*VENT UPPER*VENT / OVERLAY; RUN;