Statistics 512 Midterm 2 Spring 2006 Statistics 512 Midterm 2 April 11, 2006 The following rules apply. 1. You may bring with 3 sheets of paper, double-sided with any information you need. 2. You may use a calculator. 3. You may not collaborate or copy. 4. You may not use any device, such as a cell-phone or PDA that allows you to access the internet or other outside information. 5. Failure to comply with items 3 or 4 could lead to reduction in your grade, or disciplinary action. I have read the rules above and agree to comply with them. Signature ________________________________________________ Name (printed) ___________________________________________ problem your score 1 2 3 Total 1 total points Statistics 512 Midterm 2 Spring 2006 1. PBG is a drug known to raise blood pressure in some animals. As a pilot study the researchers wished to know if rabbits vary in their response to the drug. 5 rabbits were used in the study. The change in blood pressure after administering 12.50 mg of PBG was recorded. The effects of PBG are very short-term. Hence it was possible to repeat the experiment on every rabbit, giving 2 measurements per rabbit. a) Write the one way ANOVA model for these data assuming that rabbit is a fixed effect. Be sure to define all of your notation and include any constraints and distribution assumptions. b) Using the same notation as part (a) write the one-way ANOVA model for these data assuming that rabbit is a random effect. You do not need to redefine the variables, but you should include any constraints and distribution assumptions. 2 Statistics 512 Midterm 2 Spring 2006 c) Is it more reasonable to assume that rabbit is a fixed effect or a random effect? Briefly justify your answer. d) Under the fixed effects model what are: The mean response for rabbit 1: The covariance between the two responses for rabbit 1: The covariance between the first response for rabbits 1 and 2: 3 Statistics 512 Midterm 2 Spring 2006 d) Under the random effects model what are: The mean response for rabbit 1: The covariance between the two responses for rabbit 1: The covariance between the first response for rabbits 1 and 2: e) The investigators decided to use the random effects model. Complete the ANOVA table. Source rabbit Residual DF Sum of Squares 4 2.198500 5 2.422500 Mean Square F pvalue 0.5496 0.4845 XXXXXX XXXXXX 4 Statistics 512 Midterm 2 Spring 2006 f) Test whether or not there is a statistically significant rabbit effect. State the null and alternative hypotheses in terms of the parameters, give the p-value for the test, and state your conclusions in terms of correlations among observations. g) The average response for Rabbit 1 was 1.61. When asked to estimate the mean response for Rabbit 1, SAS PROC GLM obtains the estimate 1.61, but SAS PROC MIXED obtains the estimate 1.80. Should we complain to SAS that there is a mistake in PROC MIXED? Briefly explain your answer. 5 Statistics 512 Midterm 2 Spring 2006 2. PBG is a drug known to raise blood pressure in some animals. 5 rabbits were used in a study of PBG. Each rabbit was administered one of the 6 doses of PBG: 6.25, 12.50, 25, 50, 100, 200 mg. The response is the difference in blood pressure before and after the PBG dose was administered. One question of interest is whether the effect of PBG is linear in dose. Since the effects of PBG are very short-term, each rabbit was given each dose twice, in random order, so that there are 12 measurements (2 at each dose) for every rabbit. Within each rabbit, the measurements are thought to be independent. a) Should dose of PBG be considered a fixed or random effect in this study. Briefly justify your answer. b) Below is a boxplot of the response as a function of dose. What assumption of ANOVA appears to be violated? 40 30 d e l t a B P 20 10 0 6. 25 12. 5 25 50 100 dose 6 200 Statistics 512 Midterm 2 Spring 2006 c) The investigators decided that the appropriate response variable is log(BPfinal/BPinitial). The investigators decided to fit a 2-way ANOVA model with a random effect for rabbit and a fixed effect for PBG. Write out the factor effects model for this experiment. Be sure to define all terms and include all constraints and distribution assumptions. 7 Statistics 512 Midterm 2 Spring 2006 d) Using the model you wrote in part c, what is the covariance between the two measurements taken on the same rabbit at dose 12.5? e) Using the model you wrote in part c, what is the covariance between two measurements taken on different rabbits at dose 12.5? 8 Statistics 512 Midterm 2 Spring 2006 f) For the model you wrote in part c, what is the variance of the average response (averaged over all measurements on all 5 rabbits) at dose=12.50? g) Fill in the blanks in the ANOVA table below (remembering that the data are balanced): Source dose rabbit rabbit*dose Residual DF 5 4 20 30 Mean Square 16.316275 0.3638 0.239129 0.441739 9 F p-value xxxx xxxxxx Statistics 512 Midterm 2 Spring 2006 SAS gives the following table of Expected Mean Squares for the effects in the model: Source dose rabbit rabbit*dose Residual . Expected Mean Var(Residual) Var(Residual) Var(Residual) Var(Residual) Square + 2 Var(rabbit*dose)+ Q(dose) + 2 Var(rabbit*dose) + 12 Var(rabbit) + 2 Var(rabbit*dose) . h) Using the method of moments (also called the ANOVA estimator) estimate variance component for rabbit*dose. (Your answer should be a number, not a formula.) i) The investigators also decided to try a REML analysis of the data. The type 3 test of fixed effects for this analysis is given below. Since the data are balanced, why is this test different than the test in the ANOVA table in part g? Type 3 Tests of Fixed Effects Effect dose Num DF 5 Den DF 50 F Value 45.24 10 Pr > F <.0001 Statistics 512 Midterm 2 Spring 2006 j) An initial objective of the study is to determine if the effect of PBG on the change in blood pressure is linear. Since the response variable is now log(BPfinal/BPinitial) the investigators propose to determine if the response is linear in log(PBG). Is this the same hypothesis? Justify your response. 11 Statistics 512 Midterm 2 Spring 2006 3. PBG is a drug known to raise blood pressure in some animals. 5 rabbits were used in a study of PBG. Each rabbit was administered one of the 6 doses of PBG: 6.25, 12.50, 25, 50, 100, 200 mg. The response is log(BPfinal/BPinitial) before and after the PBG dose was administered. Since the effects of PBG are very short-term, each rabbit was given each dose twice, in random order, so that there are 12 measurements (2 at each dose) for every rabbit. Within each rabbit, the measurements are thought to be independent. Normal blood pressue in a rabbit is about 87 mm Hg. However, handling rabbits during experiments can raise their blood pressure and this might have an effect on the blood pressure elevation induced by PBG. To control for this effect, the blood pressure measurement prior to administration of PBG was used as a covariate in the experiment (BPinit). a) Write a linear model for this experiment assuming that there is a linear effect of initial blood pressure and no interaction between initial blood pressure and the other factors in the model. In this model, rabbit should be a random effect and dose should be a fixed effect Be sure to define all of your notation and include any constraints and distribution assumptions. 12 Statistics 512 Midterm 2 Spring 2006 For the remainder of this problem you can assume that the necessary distribution assumptions are satisfied. b) Below is the Type 3 analysis of variance for the model that includes dose, inital blood pressure, the dose*initial blood pressure interaction, and random effects for rabbit and rabbit*dose. Test whether there is an interaction between dose and initial blood pressure. Type 3 Analysis of Variance Source DF 5 Sum of Squares 2.2365 Mean Square 0.4473 dose initBP initBP*dose rabbit 1 5 4 1.6302 1.3515 1.5817 1.6302 0.2703 0.3954 rabbit*dose 20 4.1632 0.2081 Residual 24 5.0067 0.2086 Expected Mean Square Var(Residual) + 0.0081 Var(rabbit*dose) + Q(dose) Var(Residual) + Q(initBP,initBP*dose) Var(Residual) + Q(initBP*dose) Var(Residual) + 1.6548 Var(rabbit*dose) + 9.9288 Var(rabbit) Var(Residual) + 1.8035 Var(rabbit*dose) Var(Residual) Null and Alternative Hypotheses: F-statistic d.f. for F p-value Conclusion: 13 Statistics 512 Midterm 2 Spring 2006 c) The objective of the experiment is to determine whether there is an effect of dose of PBG. Why is it important to establish whether or not there is an interaction between dose and initial blood pressure? d) Some investigators would also fit an interaction between initial blood pressure and the random effect "rabbit". What is the meaning of this interaction and should it be considered a fixed or random effect? 14 Statistics 512 Midterm 2 Spring 2006 e) The investigators decided that the model with no interaction between initial blood pressure and the other factors was appropriate, and fitted an analysis of covariance model with random effects for rabbit and rabbit*dose, and fixed effects for dose. Part of the resulting output is below. Is there a statistically significant dose effect? Briefly justify your answer. Type 3 Tests of Fixed Effects Effect Num DF Den DF F Value Pr > F dose initBP 5 1 18.5 41.6 57.33 25.46 <.0001 <.0001 f) The investigators were very surprised to see fractional degrees of freedom for the F-statistic, pointing out that the tables include only whole numbers. Why are there fractional degrees of freedom? 15 Statistics 512 Midterm 2 Spring 2006 g) The investigators wanted to use the results of this experiment to select levels of PBG to use in another experiment with a drug that is supposed to reduce the effect of PBG. The target is to find 2 levels of PBG for which the response will be close to log(10) and log(20) respectively. Should the cell means or adjusted cell means be used for selecting these 2 levels? Briefly justify your answer. You can assume that the new experiment will involve similar levels of handling of the rabbits, and therefore similar levels of the covariate. 16