| box_m | R Documentation |
Performs the Box's M-test for homogeneity of covariance matrices obtained from multivariate normal data according to one grouping variable. The test is based on the chi-square approximation.
See the Datanovia tutorial Homogeneity of Variance Test in R for a worked walkthrough.
box_m(data, group)
data |
a numeric data.frame or matrix containing n observations of p variables; it is expected that n > p. |
group |
a vector of length n containing the class of each observation; it is usually a factor. |
A data frame containing the following components:
statistic |
an approximated value of the chi-square distribution. |
parameter |
the degrees of freedom related of the test statistic in this case that it follows a Chi-square distribution. |
p.value |
the p-value of the test. |
method |
the character string "Box's M-test for Homogeneity of Covariance Matrices". |
The Datanovia tutorial: Homogeneity of Variance Test in R.
data(iris)
box_m(iris[, -5], iris[, 5])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.