simu_fwer_emp: Simulate Family Wise Error Rate (FWER) empirically

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

View source: R/simu_fwer_emp.R

Description

This function simulate family wise error rate or test type I error rate

Usage

1
simu_fwer_emp(s, m, alphaVec, max.group = 5L)

Arguments

s

number of replication in a simulation

m

total number of hypothesis test

alphaVec

a vector of significance levels

max.group

maximum number of p-value groups to be used, minimum is 5

Details

This function generate pvalues times form uniform(0, 1) then applying OPWeight method to obtain the Familly Wise Error Rate (FWER)

Value

a matrix of fwer for different methods

Author(s)

Mohamad S. Hasan, mshasan@uga.edu

References

Hasan and Schliekelman (2017)

See Also

qvalue prob_rank_givenEffect weight_binary weight_continuous

Examples

1
2
3
simVal = 1  # in actual case use at least simVal = 1000
set.seed(123)
typeIerror_mat = sapply(simVal, simu_fwer_emp, m = 10000, alphaVec = .05)

mshasan/empOPW documentation built on March 1, 2021, 4:19 a.m.