How to run a test for equal variances
- Copy a group name column and a measurement column together with the header.
- Select the response column and the group column (3 or more levels) and choose the test method.
- Press Analyze and check the p-value in the test summary and the standard deviation confidence intervals by group.
Worked example with sample data
The sample data are 12 fill volume measurements (mL) from each of 4 filling lines (Line 1 to 4). The Line column is the group column and the Fill volume column the response column.
The standard deviations are 0.7064 (Line 1), 1.074 (Line 2), 2.24 (Line 3) and 1.14 mL (Line 4), so only Line 3 is noticeably larger. Bartlett's statistic is 15.21 with 3 degrees of freedom and p-value 0.001649, so the four lines do not have equal variances.
In the standard deviation chart with confidence intervals, Line 3's interval sits above the others, showing that Line 3 is the one that differs. The means of all four lines are similar, between 500.1 and 500.5 mL.
Testing the same data with Levene (mean-based) gives p=0.04771 and Brown-Forsythe (median-based) gives p=0.07694. The more robust the method, the larger the p-value, so check whether the one outlier on Line 3 affects the result.
Test methods
Bartlett's test assumes normality but has high power, and uses the chi-square distribution with k-1 degrees of freedom. Levene (mean-based) and Brown-Forsythe (median-based) run an analysis of variance on the distance of each value from its group center, so they are robust to non-normality (degrees of freedom k-1, N-k).
What the result shows
Descriptive statistics by group (N, mean, variance, standard deviation), a test summary, a box plot by group, an individual value plot, and the standard deviation of each group with a confidence interval. Groups with fewer than 2 valid values are excluded.
How to read the test for equal variances
- If the p-value is below the significance level, at least one group has a different spread. To see which, look for an interval in the standard deviation chart that does not overlap the others.
- If only Bartlett is significant and Levene/Brown-Forsythe are not, non-normality may have made Bartlett overreact.
- If equal variances are doubtful, use Welch ANOVA instead of one-way ANOVA to compare the means.
Frequently asked questions
What if there are only 2 groups?
This test needs 3 or more groups. For 2 groups, use the 2-variance test.
Which method should I choose?
Bartlett if the data are close to normal; Brown-Forsythe is a safe choice when there is skewness or outliers.
Is it the same as Minitab?
Bartlett and Levene (median-based = Brown-Forsythe) use the same formulas, so the values are the same.