srp: Stable retrospective power

Description Usage Arguments Value See Also Examples

Description

srp uses p-values and false discovery rate (FDR) to calculate stable retrospective power.

Usage

1
srp(pvalues, method = "lfdr", FDR = 0.05, ...)

Arguments

pvalues

A vector of raw p-values.

method

estimation method passed to limma::propTrueNull. Choices are "lfdr", "mean", "hist" or "convest".

FDR

A level at which to control the false discovery rate (FDR). Deafults to 0.05.

...

Additional arguments passed to limma and propTrueNull.

Value

A data.frame containing: SRP that is the estimated stable retrospective power. pi0 propotion of the true non-null effects. fp the number of the statistically significant effects that are likely to be false positives. rs the number of statistically significant true effects seen in this study that will most likely come up as significant in a replication study. ud the number undiscovered results awaiting to be uncovered by replication studies.

See Also

limma and propTrueNull how pi0 is calculated and for arguments.

Examples

1
2
3
4
5
6
7
8
z <- rnorm(1000)
z[1:200] <- z[1:200]+10
1800/2000
p <- 2*pnorm(-abs(z))

# Calculate SRP
pw <- srp(p, FDR = 0.05)
pw

tpall/SRP documentation built on May 31, 2019, 6:46 p.m.