The primary objective of a phase II clinical trial of a new drug or regimen is to determine whether it has sufficient biological activity against the disease under study to warrant more extensive development.
This function calculates the sample size needed in a Fleming 2-stage design which is a two-stage design that is optimal in the sense that the expected sample size is minimized if the regimen has low activity subject to constraints upon the size of the type 1 and type 2 errors.
Two-stage designs which minimize the maximum sample size are also determined.
This type of design also allows stopping for efficacy

fleming2stage(
  p0,
  pa,
  alpha,
  beta,
  eps = 0,
  N_min,
  N_max,
  int = 0,
  int_window = 0.025,
  opt_under = "H0",
  CI_type = "Koyama"
)

Arguments

p0

probability of the uninteresting response (null hypothesis \(H0\))

pa

probability of the interesting response (alternative hypothesis Ha)

alpha

Type I error rate \(P(reject H0|H0)\)

beta

Type II error rate \(P(reject Ha|Ha)\)

eps

tolerance default value = 0.005

N_min

minimum sample size value for grid search

N_max

maximum sample size value for grid search

int

pre-specified interim analysis percentage information

int_window

window around interim analysis percentage (e.g. 0.5 +- 0.025). 0.025 is default value

opt_under

optimality under "H0" or "Ha"

CI_type

"Koyama", see getCI_Koyama, or any type for binom.confint

Value

a data.frame with elements

  • n1: total number of patients in stage1

  • n2: total number of patients in stage2

  • N: total number of patients=n1+n2

  • r1: ("r" stands for "rejection") threshold for "rejecting" Ha: if x1<=r1 --> stop for futility at first stage

  • r2: ("r" stands for "rejection") threshold for "rejecting" Ha: if x1+x2<=r --> futility at second stage

  • a: ("a" for "acceptance") threshold for "accepting" Ha= stop for efficacy at first stage

  • eff: (r2 + 1)/N

  • CI_LL: (1-2*alpha) CI lower limit

  • CI_UL: (1-2*alpha) CI upper limit

  • EN.p0: expected sample size under H0

  • PET.p0: probability of terminating the trial for futility at the end of the first stage under H0

  • EN.pa: expected sample size under Ha

  • PET.pa: probability of terminating the trial for efficacy at the end of the first stage under Ha

  • MIN: column indicating if the design is the minimal design

  • OPT: column indicating if the setting is the optimal design

  • ADMISS: column indicating if the setting is the admissible design

  • alpha: the actual alpha value which is smaller than alpha_param + eps

  • beta: the actual beta value where which is smaller than beta_param + eps

  • p0: your provided p0 value

  • pa: your provided pa value

  • alpha_param: your provided alpha value

  • beta_param: your provided beta value

Details

if x1<=r1 --> stop futility at first stage
if r1<x1<a --> proceed to second dtage
if x1>=a --> stop efficacy at first stage
if (x1+x2)<=r2 --> futility at second stage
if (x1+x2)> r2 --> efficacy at second stage
So PET.H0=P_H0(X1<=r1)+P_H0(X1>=a1)

References

Mander AP, Thompson SG. Two-stage designs optimal under the alternative hypothesis for phase II cancer clinical trials. Contemporary Clinical Trials 2010;31:572–578 Qin F et al. Optimal, minimax and admissible two-stage design for phase II oncology clinical trials. BMC Medical Research Methodology 2020;20:126

Examples

result_H0 <-fleming2stage(p0 = 0.3, pa = 0.5, alpha = 0.1, beta = 0.1, eps = 0, N_min = 3,
N_max = 50, opt_under="H0")
result_Ha <-fleming2stage(p0 = 0.3, pa = 0.5, alpha = 0.1, beta = 0.1, eps = 0, N_min = 3,
N_max = 50, opt_under="Ha")