* Note that in Section 3.6 the book does the Brown Forsythe test for
just two groups using a t-test. With two groups use of the t-test is
equivalent to the use of the F-test that we used in notes in the class.
We have done it in terms of the F-test as this automatically handles more
than two groups.
* BROWN-FORSYTHE/MODIFIED LEVENE TEST IN SAS.
The later versions of SAS have a Brown-Forsythe option in ANOVA.
If you run an anova the residuals as the respons an with hovtest=bf
you get the same test that we developed by finding the d's (deviations
of residuals from the median) and running a one-way anova on the d's.
To illustrate consider the Kishi data with the developments in the notes where
we obtained d directly by obtaining the medians and using them. Then using
proc anova;
class group;
model d =group;
run;
yielded
The ANOVA Procedure
Dependent Variable: d
Sum of
Source DF Squares Mean Square F Value Pr > F
Model 2 14.5820939 7.2910469 1.78 0.1865
Error 28 114.4087282 4.0860260
The F-test of 1.78 with a p-value of .1865 is the Brown-Forsythe test.
We can also use
proc anova data=result;
class group;
model resid=group;
means group/hovtest=bf;
but notice I have now used hovtest=bf rather than levene as done in
class. This first ANOVA, which I had left out of the class notes, gives
Dependent Variable: resid Residual
Sum of
Source DF Squares Mean Square F Value Pr > F
Model 2 1.1466860 0.5733430 0.05 0.9512
Error 28 320.0978299 11.4320654
Corrected Total 30 321.2445159
The F-test here is testing the hypothesis that the expected value of the
residuals is equal across groups. It should be if the model is correct
as the true errors have mean 0. So, not surprisingly this is non signficiant.
The second part of this anova is testing equality of variances of the
residuals, which with Brown-Forsythe option is doing exactly what
we did by creating the d's earlier.
Brown and Forsythe's Test for Homogeneity of resid Variance
ANOVA of Absolute Deviations from Group Medians
Sum of Mean
Source DF Squares Square F Value Pr > F
group 2 14.5821 7.2910 1.78 0.1865
Error 28 114.4 4.0860