# NOT RUN {
# using the defaults:
# partial replicate design, targetpower=80%,
# true assumed ratio = 0.90, 1E+5 simulated studies
# ABE limits, PE constraint 0.8 - 1.25
# EMA regulatory settings
# Heterogenicity (CVwT 0.4, CVwR 0.3)
# compare results and run times
# }
# NOT RUN {
CV <- c(0.4, 0.3)
expl <- data.frame(method = c("subject simulations", "\'key\' statistics"),
n = NA, power = NA, seconds = NA)
start <- proc.time()[[3]]
expl[1, 2:3] <- sampleN.scABEL.sdsims(CV = CV, print = FALSE,
details = FALSE)[8:9]
expl[1, 4] <- proc.time()[[3]] - start
start <- proc.time()[[3]]
expl[2, 2:3] <- sampleN.scABEL(CV = CV, print = FALSE,
details = FALSE)[8:9]
expl[2, 4] <- proc.time()[[3]] - start
print(expl, row.names = FALSE)
# }
# NOT RUN {
# should result in a sample size n=69, power=0.80198 for
# the subject simulations and n=66, power=0.80775 for the
# 'key' statistics
# }
Run the code above in your browser using DataLab