Beruflich Dokumente
Kultur Dokumente
Analysis of Variance
Analysis of variance is a technique that
partitions the total sum of squares of
deviations of the observations about their
mean into portions associated with
independent variables in the experiment
and a portion associated with error
Analysis of Variance
2. Variables
⚫ One Nominal Independent Variable
⚫ One Continuous Dependent Variable
Assumptions
H0: µ1 = µ2 = µ3 = ... = µp
➢ All population means are equal
➢ No Treatment effect
Response, Y
Y
Response, Y
Y3
Y
Y2
Y1
Response, Y
Y3
Y2
Y1
Do Not
Reject H0
0 F
Fa ( p - 1, n - p )
Always One-Tail!
Example
As a vet epidemiologist you
want to see if 3 food Food1 Food2 Food3
supplements have different 25.40 23.40 20.00
mean milk yields. You assign 26.31 21.80 22.20
15 cows, 5 per food 24.10 23.50 19.75
supplement. 23.74 22.75 20.60
Question: At the 0.05 level, is 25.10 21.60 20.40
there a difference in mean
yields?
Solution
H0: 1 = 2 = 3
Test Statistic:
Ha: Not All Equal
F = MST/MSE
= 0.05 = 23.5820/0.9211 = 25.6
1 = 2 2 = 12
Critical Value: Decision:
Reject at α = 0.05
Conclusion:
= 0.05
There is evidence that population
means are different
0 3.89 F
Summary Table - Solution
Total 15 - 1 = 14 58.2172
Two way Analysis of Variance
Two-way ANOVA
2.Variables
⚫ One Nominal Independent Variable
⚫ One Nominal Blocking Variable
⚫ One Continuous Dependent Variable
Two-way ANOVA Assumptions
1.Normality
⚫ Probability Distribution of each Block-
Treatment combination is Normal
2.Homogeneity of Variance
⚫ Probability Distributions of all Block-Treatment
combinations have Equal Variances
Two-way ANOVA Hypotheses
H0: µ1 = µ2 = µ3 = ... = µp
➢ All population means are equal
➢ No Treatment effect
are equal
X
⚫ No treatment effect 1 = 2 = 3
Ha: Not all j are equal
⚫ At least one population
f(X)
mean is different
⚫ Treatment effect
X
⚫ 1 2 ... p 1 = 2 3
The F Ratio for Two-way ANOVA
SS=SSE+SSB+SST
MST SST / ( p − 1)
F= =
MSE SSE / ( n − 1 − p + 1 − b + 1)
SST / ( p − 1)
=
SSE / ( n − p − b + 1)
Two-way ANOVA F-Test Statistic
1.Test Statistic
⚫ F = MST / MSE
• MST Is Mean Square for Treatment
• MSE Is Mean Square for Error
2.Degrees of Freedom
⚫ ν1 = p -1
⚫ ν 2 = n – b – p +1
• p = # Treatments, b = # Blocks
n = Total Sample Size
Two-way ANOVA F-Test Critical Value
Do Not α
Reject H0
0 F
Fa ( p - 1, n - p )
Always One-Tail!
Example
You wish to determine which of four brands of tires has the longest tread
life. You randomly assign one of each brand (A, B, C, and D) to a tire
location on each of 5 cars. At the 0.05 level, is there a difference in mean
tread life?
Tire Location
Left
Block Front Right Front Left Rear Right Rear
Car 1 A: 42,000 C: 58,000 B: 38,000 D: 44,000
Car 2 B: 40,000 D: 48,000 A: 39,000 C: 50,000
Car 3 C: 48,000 D: 39,000 B: 36,000 A: 39,000
Car 4 A: 41,000 B: 38,000 D: 42,000 C: 43,000
Car 5 D: 51,000 A: 44,000 C: 52,000 B: 35,000
Two-way ANOVA Solution
H0: µ1 = µ2 = µ3= µ4
Ha: Not all are equal Test Statistic: F = 11.9933
α = 0.05
ν1 = 3 ν2 = 12 Decision: Reject at α = 0.05
F
0 3.49