indTest.multi {MNormTest}R Documentation

Multivariate Normal Independence Test

Description

Test whether a set of multivariate normal random vectors are independent. The null hypothesis is "H0: The random vectors are independent of each other".

Usage

indTest.multi(data, subdim = FALSE, alpha = 0.05, verbose = TRUE)

Arguments

data

The data matrix which is a matrix or data frame. Each column represents a random variable.

subdim

The dimensions of submatrices. The default is FALSE, which means the independence of all components of the random vector will be tested.

alpha

The significance level. Default is 0.05.

verbose

A boolean value. Default is TRUE. If TRUE, the null hypothesis will be displayed. If FALSE, the test will be carried out silently.

Value

An object of class "testResult", which is a list with the following elements:

Conclusion

The conclusion of the test.

Stat

A data frame containing the statistics, p value and critical value.

SampMean

The sample mean.

SampA

The sample deviation.

SampAii

The sample deviation of submatrices.

Df

The degree of freedom.

b

The Modified factor of the statistic.

Author(s)

Xifeng Zhang

References

Huixuan, Gao. Applied Multivariate Statistical Analysis. Peking University Press, 2005: pp.92-94.

Examples

data(iris)
chart <- iris[, 1:4]
# carry out the test
test1 <- indTest.multi(chart)
test2 <- indTest.multi(chart, subdim = c(2, 1, 1))
test3 <- indTest.multi(chart, verbose = FALSE)
# get the elements
test1$Stat
test1$SampMean
test2$SampAii

[Package MNormTest version 1.1.0 Index]