Analysis of Variances
Analysis of Variances
Analysis of Variances
ANOVA
ANOVA
for comparing means between more
than 2 groups
Types of Experimental Designs
Experimental
Designs
One- Two-
Way Way
Anova Anova
EPI809/Spring 2008 3
Hypothesis of One-Way ANOVA
H0: 1 = 2 = 3 = ... = p
All Population Means are f(X)
Equal
No Treatment Effect
X
Ha: Not All j Are Equal 1 = 2 = 3
At Least 1 Pop. Mean is
Different f(X)
Treatment Effect
NOT 1 = 2 = ... = p
Or i ≠ j for some i, j. X
1 = 2 3
EPI809/Spring 2008 4
How to calculate ANOVA’s by hand…
y
10 10 10
10
(y
10 10
10
y 2 )
2
( y1 j y1 ) 2 2j ( y 3 j y 3 ) 2 ( y 4 j y 4 ) 2
The (within) group
j 1 j 1 j 1 j 1
variances
10 1 10 1 10 1 10 1
Sum of Squares Within (SSW), or
Sum of Squares Error (SSE)
10
(y
10 10
(y (y
10
y 2 )
(y
2
1j y1 ) 2 2j 3j y 3 ) 2
4j y 4 ) 2
j 1 j 1 j 1 j 1
The (within) group
variances
10 1 10 1 10 1 10 1
10 10
(y
10 10
(y ( y 3 j y 3 ) + y 4 ) 2
2
y1 ) +
2 ( y 2 j y 2 ) 2 + 4j
1j
j 1 j 3 j 1
j 1
4 10
i 1 j 1
( y ij y i ) 2 Sum of Squares Within (SSW)
(or SSE, for chance error)
Sum of Squares Between (SSB), or Sum
of Squares Regression (SSR)
4 10
Overall mean of
all 40 y
i 1 j 1
ij
observations
(“grand mean”) y
40
(y
Sum of Squares Between
Squared difference of every
4 10 4 4 10
( y
i 1 j 1
ij y i ) 2
+ 10x ( y i y ) 2
= ( y ij y ) 2
i 1 i 1 j 1
42 43 50 54
deviations) = 2060.6 72 63 59 60
71 65 64 65
Step 3) ANOVA table
Total 39 2257.1
Step 3) ANOVA table
Total 39 2257.1
Coefficient of Determination
SSB SSB
R 2
SSB SSE SST
The amount of variation in the outcome variable (dependent
variable) that is explained by the predictor (independent variable).
INTERPRETATION of ANOVA:
How much of the variance in height is explained by treatment group?
R2=“Coefficient of Determination” = SSB/TSS = 196.5/2275.1=9%