Description Usage Arguments Value Author(s) References See Also Examples
Test residuals from an analysis for homogeneity of variance. This function is a wrapper function
for leveneTest
from the car package.
1 | leveneTestSC(Data, Treatment, Residuals)
|
Data |
A data set. |
Treatment |
The name (as a string) of the treatment variable. |
Residuals |
Residuals from a model fit. |
Treatment |
The name of the treatment variable. |
Df |
The degrees of freedom. |
F value |
The value of the F-statistic. |
Pr(>F) |
The p-value corresponding to the F-statistic. |
Joe Swintek
Levene, Howard (1960) Robust tests for equality of variances In Ingram Olkin, Harold Hotelling, et al. Contributions to Probability and Statistics: Essays in Honor of Harold Hotelling. Stanford University Press. pp. 278-292.
1 2 3 4 5 6 7 8 9 | #Data
data(lengthWeightData)
#Subset the data
SubData<-lengthWeightData[lengthWeightData$Age=='16 week', ]
SubData<-SubData[SubData$Generation=='F1', ]
SubData<-SubData[SubData$SEX=='M', ]
#Run
Residuals<-aov(WEIGHT~Treatment,SubData)$residuals
wilksTest(Residuals)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.