PowerTOST update [🇷 for BE/BA]

posted by d_labes  – Berlin, Germany, 2016-02-01 20:16 (3302 d 19:02 ago) – Posting: # 15909
Views: 17,101

Dear Helmut,

❝ @Detlew: In my code I had to arbitrarily increase nstart in the second attempt, i.e., to

x <- sampleN.RSABE(CV=CV[j], theta0=GMR[k], targetpower=0.9,

❝                    design="2x2x4", print=FALSE,
❝                    details=FALSE, nstart=x[["nlast"]]*1.5)

❝ because for CV=0.305, theta0=0.82 nlast is 442.

❝ With nstart=nlast the algo stops again (n 644, power 0.89243). Currently in line 159 of the source-code imax is fixed with 100. What do you think about introducing imax as an argument like in sampleN.TOST()?


your wish is my command.

Yes, I know that the starting values of the sample size search in such extreme settings as you are using here is not always good enough to come to a result. Introducing an argument imax makes for the functions sampleN.scABEL() or sampleN.RSABE() more sense than for sampleN.TOST() itself. For the latter the starting values are generally good enough to achieve the sample size within at max. 10 iterations or so. Usually a lower number is required.

The update will need some time. In the meantime I suggest to change your code to allow more then two tries to obtain a sample size from sampleN.scABEL() or sampleN.RSABE() if you need the functionality in the near future.
Sumefink like:
  ...
  x <- sampleN.RSABE(CV=CV[j], theta0=GMR[k],
                     design="2x2x4", print=FALSE,
                     details=FALSE)
  n <- x[["Sample size"]]]

  while (is.na(n){
    # 2nd try if necessary
    x <- sampleN.RSABE(CV=CV[j], theta0=GMR[k],
                       design="2x2x4", print=FALSE,
                       details=FALSE, nstart=x[["nlast"]])
    n <- x[["Sample size"]]]
  }

Maybe it would be a good idea to introduce additionally a counter in the while loop with reaching a maximum will break that loop.

Regards,

Detlew

Complete thread:

UA Flag
Activity
 Admin contact
23,381 posts in 4,914 threads, 1,663 registered users;
42 visitors (0 registered, 42 guests [including 7 identified bots]).
Forum time: 15:18 CET (Europe/Vienna)

Science is built up with facts, as a house is with stones.
But a collection of facts is no more a science
than a heap of stones is a house.    Henri Poincaré

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