

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The concept of contrasts and interactions in analysis of variance (anova) through the lens of sas computer code. It covers one-way anova as a set of contrasts, contrasts with interactions, and simple main effects tests. The document also introduces the concept of treatment-contrast interactions and their significance.
Typology: Study notes
1 / 2
This page cannot be seen from the preview
Don't miss anything!


Refer to the computer code for today’s lectures to see how to perform these calculations in SAS.
The ANOVA null hypothesis for 4 groups H 0 : μ 1 = μ 2 = μ 3 = μ 4 is equivalent to the following set of contrasts:
L 1 : μ 1 − μ 2 = 0 L 2 : μ 1 − μ 3 = 0 L 3 : μ 1 − μ 4 = 0
For these three contrasts to be simultaneously equal to zero is equivalent to having all four means equal to each other.
For an experiment with factorial treatment structure, with 2 factors each having three levels, we can look at the treatment-combination means in the following arrangement:
B 1 2 3 1 μ 11 μ 12 μ 13 A 2 μ 21 μ 22 μ 23 3 μ 31 μ 32 μ 33
We can express questions of interest regarding an AxB interaction in the form of contrasts. The first example is simple-main-effect tests. If we wish to test the equality of factor A when factor B is held at the first level (in our police training example, we are testing the three patrols when training time is fixed at 5 hours) we wish to test H 0 : μ 11 = μ 21 = μ 31 , which is equivalent to the following set of contrasts:
L 1 : μ 11 − μ 21 = 0 L 2 : μ 11 − μ 31 = 0
The problem with simple-main-effect tests is that they involve a combination of main effects and interaction effects. If you repeat the above question for when training time is held at 10 and then 15 hours, the sum of these three simple-main-effect test sum of squares equals SSA + SSAB from the factorial model. Thus these tests are mixing main effects and interaction effects together. An alternative approach is to take a contrast in one factor, and see if it interacts with the other factor. In the police example, it may be of interest to see if the upper-class patrol - middle-class patrol contrast (call it ψ1(A) = μ 1 · − μ 2 · ) interacts with the training
time. The null hypothesis of no interaction between ψ1(A) and training is equivalent to the following set of contrasts.
L 1 : (μ 11 − μ 21 ) − (μ 12 − μ 22 ) = 0 L 2 : (μ 11 − μ 21 ) − (μ 13 − μ 23 ) = 0
If we find that this interaction is non-significant, then we may proceed to test the main effect of ψ1(A) = upper-class patrol - middle-class globally. Several of the ways that the author of our text discusses interaction can addressed in these ways.