ChenQin.test: Chen's and Qin's test for equality of two mean vectors

Description Usage Arguments Value Author(s) References Examples

Description

Performs the test from Chen and Qin (2010) for the equality of two p by 1 population mean vectors given samples of sizes n and m.

Usage

1

Arguments

X

the n by p data matrix for sample one.

Y

the m by p data matrix for sample two.

Value

ChQ

the value of the test statistic.

pvalue

the two-sided p-value for the test statistic.

Author(s)

Karl Gregory kgregory@mail.uni-mannheim.de, http://www.stat.tamu.edu/~kbgregory.

References

Chen, X. S. and Qin, Y.L. (2010). A two sample test for high dimensional data with applications to gene-set testing. The Annals of Statistics. 38(2):808–835

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 
	
data(chr1qseg)
	
	impute <- function(x) 	
	{ 	
		x[which(is.na(x))] <- mean(x,na.rm=TRUE)
		return(x)
	}
	
	X <- apply(chr1qseg$X,2,impute)
	Y <- apply(chr1qseg$Y,2,impute)
	
	ChenQin.test(X,Y)
	
	
## End(Not run)

Example output

Loading required package: fastclime
Loading required package: lattice
Loading required package: igraph

Attaching package: 'igraph'

The following objects are masked from 'package:stats':

    decompose, spectrum

The following object is masked from 'package:base':

    union

Loading required package: MASS
Loading required package: Matrix
$ChQ
           [,1]
[1,] -0.8565362

$pvalue
          [,1]
[1,] 0.3917012

highD2pop documentation built on May 2, 2019, 5:11 a.m.