Test
Effect to detect

What this calculator does

The F test for two variances asks whether two populations are equally spread out. This page answers the planning question that comes before it: how many observations do I need? Give it the variance ratio you want to be able to detect, the significance level and the power you want, and it returns the smallest equal-group sample size that reaches that power.

Groups are assumed to be the same size (n₁ = n₂). If you already have your sample sizes and want the power they give you — including unequal groups — use the F-test power calculator instead.

The effect size is a ratio, not a difference

For this test the effect size is the ratio of the two variances, σ₁²/σ₂². A ratio of 1 means the variances are identical and there is nothing to detect. Cohen's conventions for this test are 1.02 small, 1.15 medium and 1.35 large.

A ratio below 1 is the same effect seen from the other side: 0.7 and 1/0.7 = 1.43 describe the same design with the two groups swapped, so the calculator reads a ratio below 1 as its reciprocal when it names the effect small, medium or large.

The direction of the ratio and the direction of the test have to agree. A ratio above 1 with a left-tailed test is asking for the power to detect something in the opposite direction from the one you specified, and the power then falls as the sample grows. The calculator switches the direction for you and says so above the results.

Why this test needs normal data

The F test for two variances assumes both samples come from normal populations, and unlike the t test it is not robust when they do not. With heavy-tailed data its real false-positive rate can be far from the significance level you chose, which makes a power calculation for it optimistic in a way no sample size can fix. If you cannot rely on normality, Levene's test is the safer choice.

How to read the power curve

The curve shows the power the test would have at every sample size, with your target marked as a dashed line and the answer marked on the curve. Hover it to read the power at any n. The curve is steep at first and then flattens: past a certain point extra observations buy very little power, which is usually the most useful thing the picture tells you.

If the required sample size is impractical

Variance tests need large samples — far larger than tests about means — because a variance is estimated much less precisely than a mean. A ratio close to 1 can easily demand tens of thousands of observations per group. If the answer is out of reach, the honest options are to accept a lower power, to look for a larger effect, or to ask whether the difference in spread is one you actually need to test for.

Related calculators