print.LeveneT2 {smsets} | R Documentation |
Prints Levene's test based on Hotelling's T^2
test
Description
Prints the results produced by LeveneT2
, consisting of
a Levene's test for two multivariate samples based on Hotelling's T^2
test.
Usage
## S3 method for class 'LeveneT2'
print(x, long = FALSE, ...)
Arguments
x |
an object of class |
long |
a logical variable indicating whether a long output is desired
( |
... |
further arguments passed to or from other methods. |
Value
Displays the results of the comparison of multivariate variation in two
samples in which data values are transformed into absolute deviations from
their respective sample medians, and mean vectors of absolute deviations are
compared using Hotelling's T^2
test. The argument x
, invisibly, as
for all print methods, is a list of class "LeveneT2
". This print
method provides two sorts of output depending on whether the long
argument
is TRUE
or FALSE
(the default). The "short" output displays:
A description of the analysis.
The data frame analyzed.
The names of responses in the data frame.
The labels of the two-level group factor (samples), with an order determined by the argument
level1
inLeveneT2
.The value of Hotelling's
T²
-statistic.The value of the F-statistic with its corresponding degrees of freedom for numerator and denominator. When the within-sample covariance matrices of absolute deviations around medians are not assumed equal (
var.equal = FALSE
), these degrees of freedom are approximated using the Nel and van der Merwe's (1986) solution to the multivariate Behrens-Fisher problem, as implemented in Hotelling package (Curran and Hersh, 2021).The P-value.
In addition to the above information, the "long" output lists:
Sub-data frames containing the original responses and medians, separately for each sample.
The absolute deviations from sample medians for samples 1 and 2.
Vectors of mean absolute deviations around medians for samples 1 and 2, used in Hotelling's
T²
test.
References
Curran, J. and Hersh, T. (2021). Hotelling: Hotelling's T^2 Test and Variants. R package version 1.0-8, https://CRAN.R-project.org/package=Hotelling.
Nel, D.G. and van de Merwe, C.A. (1986). A solution to the multivariate Behrens-Fisher problem. Comm. Statist. Theor. Meth., A15, 12, 3719-3736.
Examples
data(sparrows)
LeveneT2.sparrows <- LeveneT2(sparrows, group = Survivorship, level1 = "S",
var.equal = TRUE)
# Long output
print(LeveneT2.sparrows, long = TRUE)