Testing for
Homoscedasticity

When you use ANOVA (and t-Test) you are making the assumption that all levels (= groups = categories) have equal variances. This is very important because analysis of variance is basically what the name indicates. If our variances within are all over the place and then we use them in comparison with variance between, the accuracy of the test will be in jeopardy.

Recall our example with level of pathogenicity in three different bacterial populations. In order to meet the assumption of homoscedasticity, the variance within the Hoh River data set must be equal (statistically equivalent) to that of Kettle Creek and Yellowstone Prong.

Once again, a mathematician/statistician came to our rescue with a quick test for homoscedasticity. This individual made a cumulative probability distribution of a statistic that is equal to the ratio of the largest to the smallest of several sample variances. The statistic is called F_{max}.

Hypotheses

H_{o}: σ_{H}^{2} = σ_{K}^{2} = σ_{Y}^{2}

H_{A}: Not all variances
are
equal.

Recall that we typically use s^{2} to estimate
σ^{2}.

Test Statistic = F_{max} = s^{2}_{max}
/ s^{2}_{min}

Now all we need to do is look at our data sets or ANOVA output.

F_{max} = s^{2}_{max}
/ s^{2}_{min} = 132.044 / 123.289 = 1.0710

Time for another "gut-feeling moment."

If the maximum and minimum variance values were identical F_{max}
would equal 1.0000 and therefore we would certainly conclude that the
assumption of equal variances was met. However, life isn't
always (or ever) perfect. Consequently, we need a method to
determine how high F_{max} can be before we
decide to reject the null hypothesis and run for the hills of
nonparametric testing (or transformations).

Critical F_{max} Value = F_{max
α [k, n-1]}

where,

α = 0.05

k = number of levels (groups, categories)

n = number of observations per sample

F_{max} Table for α = 0.05

_{max }≥ F_{max
α [k, n-1]},
reject the H_{o}.

In other words, not all of the variances are equal.

For our example,

Calculated F_{max }= 1.0710

F_{max 0.05 [3, 9]} = 5.34

Given that 1.0710 is not ≥ 5.34,

we fail to reject the H_{o}.

Happy Days Are Here Again!

When you use ANOVA (and t-Test) you are making the assumption that all levels (= groups = categories) have equal variances. This is very important because analysis of variance is basically what the name indicates. If our variances within are all over the place and then we use them in comparison with variance between, the accuracy of the test will be in jeopardy.

Recall our example with level of pathogenicity in three different bacterial populations. In order to meet the assumption of homoscedasticity, the variance within the Hoh River data set must be equal (statistically equivalent) to that of Kettle Creek and Yellowstone Prong.

Once again, a mathematician/statistician came to our rescue with a quick test for homoscedasticity. This individual made a cumulative probability distribution of a statistic that is equal to the ratio of the largest to the smallest of several sample variances. The statistic is called F

Hypotheses

H

H

Recall that we typically use s

Test Statistic = F

Now all we need to do is look at our data sets or ANOVA output.

F

Time for another "gut-feeling moment."

If the maximum and minimum variance values were identical F

Critical F

where,

α = 0.05

k = number of levels (groups, categories)

n = number of observations per sample

F

d.f.* (n-1) |
Number of Levels (Groups, Categories) (k) |
||||||||||

2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | |

2 | 39.0 | 87.5 | 142.0 | 202.0 | 266.0 | 333.0 | 403.0 | 475.0 | 550.0 | 626.0 | 704.0 |

3 | 15.4 | 27.8 | 39.2 | 50.7 | 62.0 | 72.9 | 83.5 | 93.9 | 104.0 | 114.0 | 124.0 |

4 | 9.60 | 15.5 | 20.6 | 25.2 | 29.5 | 33.6 | 37.5 | 41.1 | 44.6 | 48.0 | 51.4 |

5 | 7.15 | 10.8 | 13.7 | 16.3 | 18.7 | 20.8 | 22.9 | 24.7 | 26.5 | 28.2 | 29.9 |

6 | 5.82 | 8.38 | 10.4 | 12.1 | 13.7 | 15.0 | 16.3 | 17.5 | 18.6 | 19.7 | 20.7 |

7 | 4.99 | 6.94 | 8.44 | 9.70 | 10.8 | 11.8 | 12.7 | 13.5 | 14.3 | 15.1 | 15.8 |

8 | 4.43 | 6.00 | 7.18 | 8.12 | 9.03 | 9.78 | 10.5 | 11.1 | 11.7 | 12.2 | 12.7 |

9 | 4.03 | 5.34 | 6.31 | 7.11 | 7.80 | 8.41 | 8.95 | 9.45 | 9.91 | 10.3 | 10.7 |

10 | 3.72 | 4.85 | 5.67 | 6.34 | 6.92 | 7.42 | 7.87 | 8.28 | 8.66 | 9.01 | 9.34 |

12 | 3.28 | 4.16 | 4.79 | 5.30 | 5.72 | 6.09 | 6.42 | 6.72 | 7.00 | 7.25 | 7.48 |

15 | 2.86 | 3.54 | 4.01 | 4.37 | 4.68 | 4.95 | 5.19 | 5.40 | 5.59 | 5.77 | 5.93 |

20 | 2.46 | 2.95 | 3.29 | 3.54 | 3.76 | 3.94 | 4.10 | 4.24 | 4.37 | 4.49 | 4.59 |

30 | 2.07 | 2.40 | 2.61 | 2.78 | 2.91 | 3.02 | 3.12 | 3.21 | 3.29 | 3.36 | 3.39 |

60 | 1.67 | 1.85 | 1.96 | 2.04 | 2.11 | 2.17 | 2.22 | 2.26 | 2.30 | 2.33 | 2.36 |

∞ | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 | 1.00 |

* Keep in mind that the n
in degrees of freedom (n-1) is equal to the sample size within a single
level (group, category). If your sample sizes are not equal,
but they
are approximately the same, use the smaller n to calculate
degrees of freedom. [Support for the previous statement: Sheskin, David J., 2004. Handbook of Parametric and Nonparametric Statistical Procedures, Third
Edition. Chapman & Hall/CRC. (page 490: "With unequal
sample sizes, for the most conservative test of the null hypothesis, we
employ the smaller of the two sample size values...")] Please note, however, that being more conservative
means that it is more difficult to reject the null hypothesis leading
one to conclude that there is insufficient evidence for stating that
the variances are different. This increases the chances of
concluding that variances are equal when in fact they are not. If
the larger sample size is used, you're less likely to make this
mistake. Both approaches are supported, but keep in mind that
your choice of statistical test (parametric or nonparametric) may
depend on your decision; choosing the smaller sample size is more
likely to lead you to a parametric test (equal variances). A bit
of documented subjectivity in statistics!

The above table is a modified version (α = 0.05 only) of F_{max} tables
frequently found in statistics books and on-line sources. To
the best of my knowledge, the original source was an article published
by H.A. David in 1952 (Biometrika 39:422-424).

If Calculated FThe above table is a modified version (α = 0.05 only) of F

In other words, not all of the variances are equal.

For our example,

Calculated F

F

Given that 1.0710 is not ≥ 5.34,

we fail to reject the H

Happy Days Are Here Again!