Lab Exercise No. 7

advertisement
Lab Exercise no. 7
Goal: To go beyond the Kruskal-Wallis test and consider tailoring tests for
hypothesized patterns of alternatives.
When the research hypothesis does not specify any pattern, use a very general
test such as the Kruskal-Wallis test. If it is significant, then follow by using twosided multiple comparisons. Recommended multiple comparisons are Wilcoxon
rank tests applied to the k(k+1)/2 pairs of samples, where k is the number of
samples in the study. To control the probability of false rejections, we first
specify an experiment-wise probability of false rejection, such as .10, and then
budget this probability across the individual comparisons (Bonferroni method).
Then the probability of at least one false rejection is bounded above by the prespecified amount.
We will introduce the new methods in the context of the next example.
Maternal rats.
It is known that mother rats will retrieve babies (pups) that have strayed from the
nest. In fact, even virgin females will begin to retrieve pups and bring them back
to the nest.
Res Hyp: Maternal behavior such as retrieving pups is partially induced by
changes in the blood chemistry of female rats.
Measurement = amount of time before the female began to retrieve pups.
Experiment: 32 virgin female rats were randomly assigned to four conditions.
Treatment group: Injected with blood plasma from maternal rats
Control 1: Injected with blood plasma from virgin rats not in heat. (Proestrus)
Control 2: Injected with blood plasma from virgin rats in heat (Diestrus)
Control 3: Injected with a saline solution
The research hypothesis suggests that there should be a difference (lower
retrieval time) for the treatment group when compared to the various controls.
This suggests a pattern for the res hyp. Namely the treatment group should be
systematically lower than the controls.
The data is on the 464 web site. Copy the rats.txt data into Minitab.
1. Get the 85% CI-Boxplots and comment.
2. Why is the KW test inappropriate?
How to construct a test statistic that reflects the res hyp.
a. We first list the differences that are relevant.
b. We then combine the differences into a test statistic
c. We standardize the test statistic and compute its p-value
d. If it is significant we go back to the relevant differences and carry out a
Bonferroni analysis of those differences.
Differences of what? The rank averages. We begin by ranking the combined
data and finding the rank averages: R 1 , R 2 , R 3 , R 4
From 3:
a. R1 - R 2 , R1 - R 3 , R1 - R 4
b. Add them to get T = 3 R1 - R 2 - R 3 - R 4
c. We need a way to get the p-value. We can use a permutation
distribution. It is easier to use a normal approximation to the permutation
distribution. To do this we need the mean and standard deviation of T.
We will discuss this in lecture.
The statistic T (or C) is called a contrast because it is of the form:
C
a
T
a i2
N ( N  1)
n
12
i

a R
i
i
a i2
N ( N  1)
n
12
i
 0 . C is the standardized form of T. T has expectation 0 and
standard deviation given by the square root above. The macro contrast.mac
computes C and refers it to a standard normal distribution to get a p-value.
where
i
3. Get the contrast.mac macro from the macro folder and apply it to the rat
data. You will need to select the ai contrast coefficients for the contrast T.
4. Next, modify the macro to include the contrast coefficients and the rank
averages in the printout.
5. Finally, form an appropriate contrast and test whether the treatment
group differs from the saline group. This is the start of multiple
comparisons. We will continue this in lecture.
Write up 1-5. Due Wednesday.
Download