ST ACtg 5
ST ACtg 5
αi = µi − µ is estimated by ai = (x̄i − x)
if H0 : µ1 = µ2 = · · · = µk is rejected.
121
2) Planned Comparisons: Contrasts
122
Suppose we are really interested in answering
specific questions such as:
1. On the average do drugs have any effect
on learning at all?
2. Do subjects make more errors if given
both drugs than if given only one?
3. Do the two drugs differ in the number of
errors they produce?
H0 : λ1µ1 + λ2µ2 + · · · + λk µk = 0,
where λ1 + λ2 + · · · + λk = 0.
124
Now recalling that the square of a standard
normally distributed random variable is al-
ways χ2-distributed with df = 1, we obtain
2 P 2
denoting Q = L /( λi /ni):
Q/σ 2 ∼ χ2(1).
Furthermore, using SSW/σ 2 ∼ χ2(N −k), we
obtain that:
125
This suggests to test the null hypothesis
H0 : λ1µ1 + λ2µ2 + · · · + λk µk = 0
with a conventional t-test of the form
L
t= ∼ t(N −k).
s(L)
Example: (continued.)
1 1 1
L = X̄1 − X̄2 − X̄3 − X̄4
3 3 3
1
= 6.75 − (10.375 + 8.625 + 13.75)
3
= −4.167,
s P 2 s
M SW λi 7.38393 (1 + 3/9)
s(L) = =
n 8
= 1, 109 such that
−4.167
t= = −3.76.
1.109
The associated p-value in a two-sided test is
T.DIST.2T(3.76;28)=0.08%, and in a one-
sided test against H1 : µ1 < (µ2 + µ3 + µ4)/3,
T.DIST.RT(3.76;28)=0.04%, which provides
clear statistical evidence that the drugs con-
sidered increase error rates.
126
The remaining questions may be tackled in
an analogous way:
L s(L) t p
H0 (1) -4.167 1.109 -3.76 0.0008
H0 (2) 4.250 1.177 3.61 0.0012
H0 (3) 1.750 1.359 1.29 0.208
127
Contrasts in Excel
128
Orthogonal hypotheses
129
If the group sizes ni involved in the contrast
are not all identical, the orthogonality condi-
tion becomes
X λ1iλ2i
= 0.
ni
130
To illustrate the importance of orthogonal hypoth-
esis, assume that instead of testing the orthogonal
hypotheses H0 (1) − H0 (3) we would have tested the
original hypothesis
1 1 1
H0 (1) : µ1 − µ2 − µ3 − µ4 = 0
3 3 3
together with
H0 (4) : µ4 − µ1 = 0,
that is that error rates are the same when taking both
drugs or taking no drugs, upon the data below:
131
The two hypotheses are not orthogonal:
A1 A2 A3 A4
X̄i 5.50 5.75 5.75 9.00
λi(1) 1 -1/3 -1/3 -1/3
λi(4) -1 0 0 1
L s(L) t p
H0(1) -1.33 1.21 -1.10 0.281
H0(4) 3.50 1.49 2.36 0.026
132
Constructing Orthogonal Tests
133
A Word of Caution
Example:
Comparison of A1 and A2 (original data):
LSD:
pLSD = T.DIST.2T(2.668; 28) = 1.25%.
Bonferroni:
4·3
pB = · pLSD = 6 · 1.25% = 7.5%.
2
137
Tukey’s HSD = honestly significant difference
141
The best way to do multiple comparisons is
Tukey’s HSD, which is implemented as its
own option in the Single Factor ANOVA tool.
142