RRate-functions: Estimating Replication Rate for primary associations

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

repRateEst implements a replication rate estimation method. Two-component mixture prior is used in the estimation.

Usage

1
2
repRateEst(MUhat, SE, SE2, zalpha2, zalphaR2, boot = 100, output = TRUE, 
idx = TRUE, dir = "output", info = TRUE)

Arguments

MUhat

The observed effect size (log-odds ratio) in the primary study.

SE

The standard error of the observed log-odds ratio in the primary study.

SE2

The standard error of the observed log-odds ratio in the replication study.

zalpha2

The critical value of z-values in the primary study, i.e. z_alpha/2.

zalphaR2

The critical value of z-values in the replication study, i.e. z_alphaR/2.

boot

The resampling number of bootstrop used for estimating the credible interval of the RR.

output

Bool value. To determine whether to output the estimated results in the dir or not.

idx

The indexes of the SNPs having been further inverstigated in the replication study. We only calculate RR for primary associations with indexes in idx.

dir

The directory to save the estimated results. It has effect when output=T

info

Bool value. To determine whether to show the parematers inference results in the terminal or not.

Details

The RR estimation is based on the following two-component mixture model: mu=pi_0 delta_0+(1-pi_0) N(0, sigma_0^2).

Details can be seen the following reference paper.

Value

repRateEst returns the RR, lfdr, prediction power and infered parameters. The returened value is a LIST:

idx

The index of the SNPs which RR are estimated.

pi0

The proportion of nonassociated SNPs.

sigma02

The variance of the associated SNPs' effect sizes

RR

Estimated replication rate.

RRlow

The lower limit of the 95% CI for RR.

RRhigh

The upper limit of the 95% CI for RR.

lfdr

Estimated local false discovery rate of the primary study

lfdrLow

The lower limit of the 95% CI for lfdr.

lfdrHigh

The upper limit of the 95% CI for lfdr.

predPower

The Bayesian predictive power of the replication study.

predPowerLow

The lower limit of the 95% CI for predPower.

perdPowerHigh

The upper limit of the 95% CI for predPower.

GRR

The Global Replication Rate (Mean value of RR)

GRRlow

The lower limit of the 95% CI for GRR.

GRRhigh

The upper limit of the 95% CI for GRR.

Author(s)

Wei Jiang, Jing-Hao Xue and Weichuan Yu

Maintainer: Wei Jiang <wjiangaa@connect.ust.hk>

References

Jiang, W., Xue, J-H, and Yu, W. What is the probability of replicating a statistically significant association in genome-wide association studies?. Submitted.

See Also

RRate, SEest, repSampleSizeRR, repSampleSizeRR2, HLtest

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
alpha<-5e-6               #Significance level in the primary study
alphaR<-5e-3              #Significance level in the replication study
zalpha2<-qnorm(1-alpha/2)
zalphaR2<-qnorm(1-alphaR/2)

##Load data
data('smryStats1')        #Example of summary statistics in 1st study
n2.0<-2000                #Number of individuals in control group
n2.1<-2000                #Number of individuals in case group

SE2<-SEest(n2.0, n2.1, smryStats1$F_U, smryStats1$F_A) #SE in replication study
######  RR estimation  ######
RRresult<-repRateEst(log(smryStats1$OR),smryStats1$SE, SE2,zalpha2,zalphaR2, output=TRUE,dir='.')
RR<-RRresult$RR           #Estimated RR

RRate documentation built on May 1, 2019, 8:05 p.m.