li.chen.statistic: Li-Chen test statistic

View source: R/li_chen_test.R

li.chen.statisticR Documentation

Li-Chen test statistic

Description

This function computes the test statistic for testing equality of covariance matrices as described by Li and Chen (need citation)

Usage

li.chen.statistic(x, y)

Arguments

x

data matrix with rows representing samples and columns representing variables

y

data matrix of second group with same number of columns as x

Value

A list with two values

test.statistic

The test statistic value

p.value

The p-value

References

J. Li and S. X. Chen. Two sample tests for high-dimensional covariance matrices. Annals of Statistics, 40(2):908–940, 2012.

Examples

library(mvtnorm)
x = rmvnorm(n = 20, mean = numeric(100), sigma = diag(100))
y = rmvnorm(n = 20, mean = numeric(100), sigma = diag(100))
li.chen.statistic(x, y)

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