cov.test.n: A permutation test for assessing the informativeness of a...

Description Usage Arguments Value Author(s) References Examples

Description

The function implements a powerful statistical test for assessing the association between the p-value and a numeric covariate, exploiting the signal sparsity and potential nonlinearity. This is achieved by testing the association between two categorical variables after dichotomizing the p-values at the lower end and splitting the covariate into disjoint sets. An omnibus-type test is designed to combine evidence through various categorizations. Permutation is used to assess the statistical significance. We recommend using the covariate if the p-value is highly significant (p < 0.005).

Usage

1
2
3
4
5
6
7
8
9
cov.test.n(
  pvals,
  covariate,
  cutoffs = quantile(pvals, c(0.001, 0.005, 0.01, 0.05, 0.1, 0.2)),
  grps = c(2, 4, 8, 16, 32),
  perm.no = 999,
  n.max = 1e+05,
  silence = TRUE
)

Arguments

pvals

a numeric vector of p-values.

covariate

a numeric vector of the covariate.

cutoffs

a numeric vector of the cutoff points for dichotomizing the p-values.

grps

a vector of integer numbers specifying the numbers of breakpoints to divide the range of the covariate.

perm.no

the number of permutation to assess the significance. Deafult is 999.

n.max

an integer number specifying the maximum number of data points to be included. If the number of data points is larger than n.max, subsampling will be performed.

silence

a logical value indicating whether to print out the process of the computation.

Value

A list with the elements

stat.o

the observed test statistic.

stat.p

a vector of the test statistic from permutation.

p.value

the omnibu p-value for testing the association.

x.cut.optim

the optimal number of breakpoints for cutting the range of the covariate.

p.cut.optim

the optimal cutoff to dichotomize the p-value.

Author(s)

Jun Chen

References

Huang JY, ..., Zhang X, Chen J (2020) Leveraging biological and statistical covariates improves the detection power in epigenome-wide association testing.21(88).

Examples

1
2
3
4
data <- simulate.data(feature.no = 1000, covariate.strength = 'Moderate', covariate.model = 'pi0',
	sig.density = 'Low', sig.strength = 'L3', cor.struct = 'None')
obj <- suppressWarnings(cov.test.n(data$pvals, data$pi0.var, perm.no = 2))
obj$p.value

jchen1981/CAMT documentation built on Jan. 2, 2021, 1:44 p.m.