DPEF: Distributed Two-Sample Covariance Matrix Testing (Fisher...

View source: R/DPEF.R

DPEFR Documentation

Distributed Two-Sample Covariance Matrix Testing (Fisher Combination)

Description

Given two sets of data matrices X and Y, where X is an n_1 \times p matrix and Y is an n_2 \times p matrix, we conduct hypothesis testing of the covariance matrix between two samples. The null hypothesis is

H_0 : \Sigma_1 = \Sigma_2,

where \Sigma_1 and \Sigma_2 are the sample covariance matrices of X and Y respectively. The test is based on the method proposed by Yu, Li and Xue (2022). When the p-value is less than the significance level (generally 0.05), the null hypothesis is rejected.

Usage

DPEF(X, Y, K, alpha = 0.05)

Arguments

X

A numeric matrix of dimension n_1 \times p.

Y

A numeric matrix of dimension n_2 \times p.

K

Integer, number of blocks.

alpha

Numeric, significance level. Default is 0.05.

Value

A list with components:

stat

the test statistic.

pval

the p-value.

power

the estimated power.

fdr

the estimated false discovery rate.

Xopt

the selected block of X.

Yopt

the selected block of Y.

Examples

## Not run: 
## generate data from multivariate normal with trivial covariance
p  <- 500
n1 <- 100
n2 <- 150
K  <- 10
X <- matrix(rnorm(n1 * p), ncol = p)
Y <- matrix(rnorm(n2 * p), ncol = p)
## run test
DPEF(X, Y, K)

## End(Not run)


Docovt documentation built on Oct. 19, 2026, 5:06 p.m.

Related to DPEF in Docovt...