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

posted by Helmut Homepage – Vienna, Austria, 2020-11-29 11:21 (667 d 10:38 ago) – Posting: # 22092
Views: 4,161

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 🖖 Довге життя Україна! [image]
Helmut Schütz
[image]

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

Complete thread:

UA Flag
Activity
 Admin contact
22,391 posts in 4,685 threads, 1,595 registered users;
online 5 (0 registered, 5 guests [including 4 identified bots]).
Forum time: Tuesday 23:00 CEST (Europe/Vienna)

Statistics. A sort of elementary form of mathematics which consists of
adding things together and occasionally squaring them.    Stephen Senn

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