Sample sizes (ignoring the inflated TIE) [RSABE / ABEL]

posted by Helmut Homepage – Vienna, Austria, 2020-11-29 11:21 (297 d 01:42 ago) – Posting: # 22092
Views: 2,847

Dear Detlew,

» there is no need to define and program a new function :cool:!

Great!

library(PowerTOST)
design <- "2x2x4"
regGCC <- reg_const("user", r_const = log(1/0.75)/CV2se(0.3),
                    CVswitch = 0.3, CVcap = 0.3, pe_const = TRUE)
CV     <- sort(c(seq(0.2, 0.6, 0.1), 0.301))
res    <- data.frame(CV = CV, L.EMA = scABEL(CV, regulator = "EMA")[, 1],
                     U.EMA = scABEL(CV, regulator = "EMA")[, 2], n.EMA = NA,
                     L.GCC = scABEL(CV, regulator = regGCC)[, 1],
                     U.GCC = scABEL(CV, regulator = regGCC)[, 2], n.GCC = NA)
for (j in 1:nrow(res)) {
  res$n.EMA[j] <- sampleN.scABEL(CV = CV[j], design = design, regulator = "EMA",
                                 details = FALSE, print = FALSE)[["Sample size"]]
  res$n.GCC[j] <- sampleN.scABEL(CV = CV[j], design = design, regulator = regGCC,
                                 details = FALSE, print = FALSE)[["Sample size"]]
}
print(res, row.names = FALSE)

    CV     L.EMA    U.EMA n.EMA L.GCC    U.GCC n.GCC
 0.200 0.8000000 1.250000    18  0.80 1.250000    18
 0.300 0.8000000 1.250000    34  0.75 1.333333    28
 0.301 0.7994604 1.250844    34  0.75 1.333333    28
 0.400 0.7461770 1.340165    30  0.75 1.333333    30
 0.500 0.6983678 1.431910    28  0.75 1.333333    42
 0.600 0.6983678 1.431910    32  0.75 1.333333    58


PS: Do we have a bug in scABEL()?

CV  <- c(0.3, 0.3+10^(-6:-2))
lim <- scABEL(CV)
res <- data.frame(CV = CV, L = lim[, 1], U = lim[, 2])
print(res, row.names = FALSE)

       CV         L        U
 0.300000 0.8000000 1.250000
 0.300001 0.8000296 1.249954
 0.300010 0.8000244 1.249962
 0.300100 0.7999731 1.250042
 0.301000 0.7994604 1.250844
 0.310000 0.7943616 1.258873


Dif-tor heh smusma 🖖
Helmut Schütz
[image]

The quality of responses received is directly proportional to the quality of the question asked. 🚮
Science Quotes

Complete thread:

Activity
 Admin contact
21,691 posts in 4,534 threads, 1,541 registered users;
online 18 (0 registered, 18 guests [including 5 identified bots]).
Forum time: Wednesday 14:04 CEST (Europe/Vienna)

With four parameters I can fit an elephant,
and with five I can make him wiggle his trunk.    John von Neumann

The Bioequivalence and Bioavailability Forum is hosted by
BEBAC Ing. Helmut Schütz
HTML5