A multivariate hypothesis test for a single population mean or a difference between them. This version attempts to adjust for multivariate autocorrelation in the samples.
approx.hotelling.diff.test(
x,
y = NULL,
mu0 = 0,
assume.indep = FALSE,
var.equal = FALSE,
...
)
a numeric matrix of data values with cases in rows and variables in columns.
an optinal matrix of data values with cases in rows and variables in columns for a 2-sample test.
an optional numeric vector: for a 1-sample test, the poulation mean under the null hypothesis; and for a 2-sample test, the difference between population means under the null hypothesis; defaults to a vector of 0s.
if TRUE
, performs an ordinary Hotelling's
test without attempting to account for autocorrelation.
for a 2-sample test, perform the pooled test: assume population variance-covariance matrices of the two variables are equal.
additional arguments, passed on to spectrum0.mvar()
,
etc.; in particular, order.max=
can be used to limit the order
of the AR model used to estimate the effective sample size.
An object of class htest
with the following information:
The \(T^2\) statistic.
Degrees of freedom.
P-value.
Method specifics.
Null hypothesis mean or mean difference.
Always "two.sided"
.
Sample difference.
Estimated variance-covariance matrix of the estimate of the difference.
Estimated variance-covariance matrix of the estimate of the mean of x
.
Estimated variance-covariance matrix of the estimate of the mean of y
.
It has a print method print.htest().
Hotelling, H. (1947). Multivariate Quality Control. In C. Eisenhart, M. W. Hastay, and W. A. Wallis, eds. Techniques of Statistical Analysis. New York: McGraw-Hill.