Perform O'Brien test for equality of variances¶
Source: man/performOBrienTest.Rd · Help: ?performOBrienTest
Implements O'Brien's observation-level transformed-residual test for equality of group variances.
Usage¶
Arguments¶
model- A fitted
lmobject. data- Data frame used to fit
modeland containing the grouping variable. WhenNULL, the default, the model frame ofmodelis used, sogroupmust then be a variable of the model. The model frame holds the terms of the model rather than its variables (log(x)rather thanx), so a model that transforms a variable needsdata, as does a model with anoffset()term. group- Grouping variable name.
Value¶
An object of class htest containing the F statistic, numerator and denominator degrees of freedom, and p-value.
Details¶
For each residual within a group, O'Brien's transformation combines its squared deviation from the group mean with the group's sample variance and sample size. A one-way ANOVA of those transformed observations yields an approximate \(F_{k-1,N-k}\) test. Every group must contain at least three observations.
References¶
O'Brien, R. G. (1981). A simple test for variance effects in experimental designs. Psychological Bulletin, 89(3), 570–574.