null_estimation: A function to estimate the proportions of the three component...

Description Usage Arguments Details Value Author(s) References Examples

View source: R/null_estimation.R

Description

This is a function to estimate the proportions of the three component nulls involved in mediation testing. We developed a three component-mixture model method to estimate the proportions of nulls and provide much more accurate control of the family-wise error rate (FWER) and the false discovery rate (FDR), when compared to the standard approach using the uniform null distribution.

Usage

1
null_estimation(input_pvalues)

Arguments

input_pvalues

A matrix contains two columns of p-values for candidate mediators. Column 1 is the p-value of testing if the exposure is associated with the candidate mediator (alpha!=0). Column 2 is the p-value of testing if the candidate mediator is associated with the outcome adjusted for the exposure (beta!=0).

Details

A function to estimate the proportions of the three types of component null hypotheses:

H_{00}: alpha==0 and beta==0

H_{01}: alpha==0 and beta!=0

H_{10}: alpha!=0 and beta==0

The methodology detail can be found in Dai et al (2020).

Value

A list contains five elements.

alpha00

A numeric number represents the proportion of null H_{00}

alpha01

A numeric number represents the proportion of null H_{01}

alpha10

A numeric number represents the proportion of null H_{10}

alpha1

A numeric number represents the proportion of null alpha==0

alpha2

A numeric number represents the proportion of null beta==0

Author(s)

James Y. Dai and X. Wang

References

James Y. Dai, Janet L. Stanford, Michael LeBlanc. A multiple-testing procedure for high-dimensional mediation hypotheses, Journal of the American Statistical Association, 2020, DOI: 10.1080/01621459.2020.1765785.

Examples

1
2
3
4
5
6
7
data(snp_input)
input_pvalues <- snp_input
#To save computing time for illustration, we use 10 percent of rows (p-values)
input_pvalues <- input_pvalues[sample(1:nrow(input_pvalues),
size <- ceiling(nrow(input_pvalues)/10)),]

nullprop <- null_estimation(input_pvalues)

HDMT documentation built on Jan. 30, 2022, 1:07 a.m.