power.tcorr {FDRsampsize}R Documentation

Compute Power of the t-test for non-zero correlation

Description

Estimate power of t-test for non-zero correlation;Uses classical power formula for t-test

Usage

power.tcorr (n, alpha, rho) 

Arguments

n

sample size (scalar)

alpha

p-value threshold (scalar)

rho

population correlation coefficient (vector)

Details

For many applications, the null.effect is rho=0.

Value

vector of power estimates for two-sided tests

Examples

 power.tcorr        # show the power function
 res=fdr.sampsize(fdr=0.1,
                  ave.pow=0.8,
                  pow.func=power.tcorr,
                  eff.size=rep(c(0.3,0),c(100,900)),
                  null.effect=0)
 res

[Package FDRsampsize version 1.0 Index]