PowerTOST: sampleN.scABEL.ad() [RSABE / ABEL]

posted by Helmut Homepage – Vienna, Austria, 2024-10-31 09:41 (191 d 02:28 ago) – Posting: # 24252
Views: 3,131

Hi Antigoni,

❝ Noticed that a letter is missing below, which would not let me run the code :-)


Oops! I corrected it.

However, much easier with the function sampleN.scABEL.ad(), which was implemented in version 1.3-3 (2016-01-15) of PowerTOST.

library(PowerTOST)
CV     <- 0.4
target <- 0.9
design <- "2x2x4"
sampleN.scABEL(CV = CV, targetpower = target, design = design, details = TRUE)
# theta0 = 0.9 is the default in the HVD reference-scaling functions

+++++++++++ scaled (widened) ABEL +++++++++++
            Sample size estimation
   (simulation based on ANOVA evaluation)
---------------------------------------------
Study design: 2x2x4 (4 period full replicate)
log-transformed data (multiplicative model)
1e+05 studies for each step simulated.

alpha  = 0.05, target power = 0.9
CVw(T) = 0.4; CVw(R) = 0.4
True ratio = 0.9
ABE limits / PE constraint = 0.8 ... 1.25
EMA regulatory settings
- CVswitch            = 0.3
- cap on scABEL if CVw(R) > 0.5
- regulatory constant = 0.76
- pe constraint applied


Sample size search
 n     power
36   0.8630
38   0.8782
40   0.8924
42   0.9032


sampleN.scABEL.ad(CV = CV, targetpower = target, design = design, details = TRUE)
# using the values of above

+++++++++++ scaled (widened) ABEL ++++++++++++
            Sample size estimation
        for iteratively adjusted alpha
   (simulations based on ANOVA evaluation)
----------------------------------------------
Study design: 2x2x4 (4 period full replicate)
log-transformed data (multiplicative model)
1,000,000 studies in each iteration simulated.

Assumed CVwR 0.4, CVwT 0.4
Nominal alpha      : 0.05
True ratio         : 0.9000
Target power       : 0.9
Regulatory settings: EMA (ABEL)
Switching CVwR     : 0.3
Regulatory constant: 0.76
Expanded limits    : 0.7462 ... 1.3402
Upper scaling cap  : CVwR > 0.5
PE constraints     : 0.8000 ... 1.2500

n  42, nomin. alpha: 0.05000 (power 0.9032), TIE: 0.0557

Sample size search and iteratively adjusting alpha
n  42,   adj. alpha: 0.04256 (power 0.8914), rel. impact on power: -1.31%
n  44,   adj. alpha: 0.04326 (power 0.9052), TIE: 0.05000
Compared to nominal alpha's sample size increase of 4.8% (~study costs).

Runtime    : 12.7 seconds
Simulations: 16,400,000


To get only the sample size use

sampleN.scABEL.ad(CV = CV, targetpower = target, design = design,
                  print = FALSE)[["Sample size"]]

I leave it to you to loop over the target power, CVwR, and designs to get the plots… :-D

For examples and more elaborated [image]-scripts see this article.

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
23,424 posts in 4,927 threads, 1,669 registered users;
119 visitors (0 registered, 119 guests [including 4 identified bots]).
Forum time: 13:09 CEST (Europe/Vienna)

We should not speak so that it is possible
for the audience to understand us,
but so that it is impossible
for them to misunderstand us.    Quintilian

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