wald.statistic: Two-sample Wald test

View source: R/wald_statistic.R

wald.statisticR Documentation

Two-sample Wald test

Description

Wald-type test statistic for comparing the covariance matrices of two independent groups.

Usage

wald.statistic(x, y)

Arguments

x

data matrix of first group with rows representing samples and columns representing variables.

y

data matrix of second group.

Value

A list with two values

test.statistic

The test statistic value

p.value

The p-value

References

J. R. Schott. A test for the equality of covariance matrices when the dimension is large relative to the sample sizes. Computational Statistics and Data Analysis, 51(12):6535–6542, 2007.

Examples

library(mvtnorm)
x = rmvnorm(n = 100, mean = numeric(10), sigma = diag(10))
y = rmvnorm(n = 100, mean = numeric(10), sigma = diag(10))
wald.statistic(x, y)

dnayyala/cramp documentation built on June 27, 2023, 1:34 p.m.