R/multiarm_design.R
exitprob_multiarm.RdComputes the exit (rejection) probabilities for a multi-arm multi-stage design.
exitprob_multiarm(
M = NA_integer_,
r = 1,
theta = NA_real_,
corr_known = TRUE,
kMax = NA_integer_,
b = NULL,
a = NULL,
I = NULL,
nthreads = 0
)Number of active treatment arms.
Randomization ratio of each active arm to the common control.
A vector of length \(M\) representing the true treatment effects for each active arm versus the common control.
Logical. If TRUE, the correlation between Wald
statistics is derived from the randomization ratio \(r\)
as \(r / (r + 1)\). If FALSE, a conservative correlation of
0 is used.
Number of sequential looks.
A vector of efficacy boundaries for the max-Z statistics.
A vector of futility boundaries for the max-Z statistics.
A vector of information levels for any active arm versus the common control.
The number of threads to use (0 leaves the RcppParallel setting unchanged).
A vector exitProb of length kMax containing the
probability of rejection at each look.
The function assumes a multivariate normal distribution for the Wald statistics and all active arms share the same information level.
Ping Gao, Yingqiu Li. Adaptive multiple comparison sequential design (AMCSD) for clinical trials. Journal of Biopharmaceutical Statistics, 2024, 34(3), 424-440.
# Setup: 2 active arms vs control and 3 sequential looks.
# Information levels: equal spacing over 3 looks based on a maximum of
# 95 patients per arm, SD = 1.0
I <- 95 / (2 * 1.0^2) * seq(1, 3)/3
# O'Brien-Fleming critical values
b <- c(3.886562, 2.748214, 2.243907)
# Type I error under the global null hypothesis
p0 <- exitprob_multiarm(M = 2, theta = c(0, 0), kMax = 3,
b = b, I = I, nthreads = 1)
cumsum(p0$exitProbUpper)
#> [1] 0.0001007465 0.0058081554 0.0250000399
# Power under alternative: Treatment effects of 0.3 and 0.5
p1 <- exitprob_multiarm(M = 2, theta = c(0.3, 0.5), kMax = 3,
b = b, I = I, nthreads = 1)
cumsum(p1$exitProbUpper)
#> [1] 0.03130483 0.55104538 0.90221799