Learn R Programming

RDnp (version 1.3)

Dnp_Test: Test for Independence in High-Dimensional Data

Description

A Test Statistic for Independence in High-Dimensional Datasets

Usage

Dnp_Test(X)

Arguments

X

the data. It must be matrix.

Value

a list with 2 elements:

TestValue

The value of test statistic

pval

The p value

robust

Logical. Indicates whether the results are based on robust statistic. Here, it returns robust=FALSE

Details

Dnp_Test function tests the complete independence in high-dimensional data sets. This statistic was proposed by Najarzadeh (2021).

References

Najarzadeg, D (2021). Testing independece in high-dimensional multivariate normal data, Communication in Statistics: Theory and Methods. 50 (14): 3421-3435.

Examples

Run this code
# NOT RUN {
# Under H0
library(MASS)
data_H0<-mvrnorm(n = 20,mu = rep(0,30),Sigma = diag(30))
Dnp_Test(data_H0)

# Under H1
library(MASS)
data_H1<-mvrnorm(n = 20,mu = rep(0,30),Sigma = (diag(30)+1))
Dnp_Test(data_H1)
# }

Run the code above in your browser using DataLab