### Simulation example. ### Reference: Basu and Pan (2011). Comparison of Statistical Tests for Disease Association with Rare Variants. Genetic Epi. Downloadable from http://www.sph.umn.edu/biostatistics/research.asp ###### Copyright: Wei Pan, Division of Biostatistics, University of Minnesota ###### weip@biostat.umn.edu 10/22/10 ####################### ###################for independent RVs and CVs: as shown in Table 7 of Basu and Pan (2011) #library(thgenetics) source("aSumTest.r") #source("seqSumScoP.R") source("simRareCommonSNP.R") for(nSNP in c(8, 4, 0, 16, 32)){ for(i in 1:1000){ set.seed(i) dat<-simRareSNP(ORs=c(3,3, 2,2,2, 0.5,0.5, 0.5), nSNP=nSNP, nCSNP=4, cMAFslow=0.01, cMAFsup=0.1) res1<-aSumTest(dat$Y, dat$X, B=500) cat(res1, "\n") } }