Calculate Levene's test in Minitab

The modified Levene's test uses the absolute deviation of the observations in each treatment from the treatment median. It then assesses whether or not the mean of these deviations are equal for all treatments. If the mean deviations are equal, the variances of the observations in all treatments will be the same. The test statistic for Levene's test is the ANOVA F-statistic for testing equality of means applied to the absolute deviations.

You can do this in Minitab by making a new column where each value is the absolute value of the response minus the median of that treatment. Then perform a One-Way ANOVA using the new column as the response. The F-statistic and p-value will be the test statistic and p-value for Levene's test.

For example, suppose the responses are in C1 and the treatments are in C2, and C3-C6 are empty.

C1 C2
Responses Treatments
10 1
8 1
6 1
4 1
3 1
16 2
14 2
10 2
6 2
2 2

To perform Levene's test in Minitab for this data set:
  1. Choose Stat > Basic Statistics > 2 Variances.
  2. Click Both samples are in one column.
  3. In Samples, enter C1.
  4. In Sample IDs, enter C2. Click OK.

Test and CI for Two Variances: Responses vs Treatments

Test Null hypothesis H₀: σ₁ / σ₂ = 1 Alternative hypothesis H₁: σ₁ / σ₂ ≠ 1 Significance level α = 0.05
Test Method Statistic DF1 DF2 P-Value Bonett 2.14 1 0.143 Levene 2.20 1 8 0.176
You can verify these calculations using One-Way ANOVA:
  1. Choose Stat > Basic Statistics > Store Descriptive Statistics.
  2. In Variables, enter C1.
  3. In By variables (optional), enter C2.
  4. Click Statistics.
  5. Deselect all fields except Median.
  6. Click OK in each dialog box.
  7. Enter the treatment medians in C5.

    C1 C2 C3 C4 C5
    Responses Treatments ByVar1 Median1 Treatment Medians
    10 1 1 6 6
    8 1 2 10 6
    6 1 6
    4 1 6
    3 1 6
    16 2 10
    14 2 10
    10 2 10
    6 2 10
    2 2 10

  8. Choose Calc > Calculator.
  9. In Store result in variable, enter C6.
  10. In Expression, enter ABSO(C1-C5). Click OK.
  11. Choose Stat > ANOVA > One-Way.
  12. Choose Response data are in one column for all factor levels.
  13. In Response, enter C6.
  14. In Factor, enter C2. Click OK.

One-way ANOVA: AbsoluteValue(C1-C5) versus Treatments

Analysis of Variance Source DF Adj SS Adj MS F-Value P-Value Treatments 1 12.10 12.100 2.20 0.176 Error 8 44.00 5.500 Total 9 56.10

When you examine the output you see that the F-statistic and p-value in the One-way ANOVA table are identical with the test statistic and p-value for Levene’s test.