Adaptive design simulation tools for small trials

Anyone using open-source tooling to simulate group sequential or Bayesian adaptive designs in rare disease RCTs? I need to model 60–80 participants with 2:1 allocation and a time-to-event endpoint with potential delayed effects, and I’m after packages or workflows with clear vignettes and code for estimating operating characteristics across varying accrual and dropout.

‌⁠‍⁠​‍​‍‌⁠‌​​‍​‍​⁠‍‍​‍​‍‌‍‌⁠‌‍​⁠‌⁠​‍‌‍‍‍​‍​‍​‍⁠​​‍​‍‌‍‍⁠​‍​‍​⁠‍‍​‍​‍‌‍⁠‍‌‍‌‌‌⁠‌⁠‌‌⁠⁠‌⁠‌​‌‍⁠⁠‌⁠​​‌‍‍‌‌‍​⁠​‍​‍​‍⁠​​‍​‍‌‍‍‌‌‍‌​​‍​‍​⁠‍‍​‍​‍‌‍⁠‍‌‍‌‌‌⁠‌⁠​‍​‍​‍⁠​​‍​‍‌‍‌​​‍​‍​⁠‍‍​‍​‍​⁠​‍​⁠​​​⁠​‍​⁠‌‌​⁠​‌​⁠​​​⁠​​​⁠‌‍​‍​‍​‍⁠​​‍​‍‌‍‍​​‍​‍​⁠‍‍​‍​‍‌​‌‍‌⁠​‍​⁠‌‍‌​‍‌​⁠‍‌‌​‌‍‌​‍‍‌‌​⁠‌‌‍‌‌‍​‌‌​‍‍‌⁠​‌‌‍‍‌‌⁠‍‌​⁠​⁠‌⁠‌​​‍​‍‌⁠⁠‌​

For your 60–80, use simtrial + gsDesign2; simtrial handles accrual, dropout, 2:1, and ‘delayed effects’ — see CRAN: Package simtrial.

‌⁠‍⁠​‍​‍‌⁠‌​​‍​‍​⁠‍‍​‍​‍‌‍‌⁠‌‍​⁠‌⁠​‍‌‍‍‍​‍​‍​‍⁠​​‍​‍‌‍‍⁠​‍​‍​⁠‍‍​‍​‍‌⁠​‍‌‍‌‌‌⁠​​‌‍⁠​‌⁠‍‌​‍​‍​‍⁠​​‍​‍‌‍‍‌‌‍‌​​‍​‍​⁠‍‍​⁠‍‌​⁠‌​​⁠‌‌​⁠‌​​‍⁠​​‍​‍‌‍‌​​‍​‍​⁠‍‍​‍​‍​⁠​‍​⁠​​​⁠​‍​⁠‌‌​⁠​‌​⁠​​​⁠​​​⁠‍​​‍​‍​‍⁠​​‍​‍‌‍‍​​‍​‍​⁠‍‍​‍​‍‌⁠‌‌‌​‌​​⁠‌‍‌‍‍‌‌‍‍⁠‌‍⁠‌‌​‍‍‌‍​‌​⁠​‌‌⁠​‌‌‍‍‌​⁠‌‌‌‌​‍‌‍‌‍‌‍​⁠‌‍⁠​​‍​‍‌⁠⁠‌

And if you want a one-stop R workflow, rpact::getSimulationSurvival covers your 60–80 with 2:1, accrual/dropout, and ‘delayed effects’ via piecewise hazards, with clear vignettes: CRAN: Package rpact. Bayesian isn’t native there; if you truly need Bayesian stopping, simulate in simtrial and fit a piecewise-exponential in brms for posterior-predictive OCs, otherwise GSD should be enough.

‌⁠‍⁠​‍​‍‌⁠‌​​‍​‍​⁠‍‍​‍​‍‌‍‌⁠‌‍​⁠‌⁠​‍‌‍‍‍​‍​‍​‍⁠​​‍​‍‌‍‍⁠​‍​‍​⁠‍‍​‍​‍‌⁠​‍‌‍‌‌‌⁠​​‌‍⁠​‌⁠‍‌​‍​‍​‍⁠​​‍​‍‌‍‍‌‌‍‌​​‍​‍​⁠‍‍​⁠‍‌​⁠‌​​⁠‌‌​⁠‌​​‍⁠​​‍​‍‌‍‌​​‍​‍​⁠‍‍​‍​‍​⁠​‍​⁠​​​⁠​‍​⁠‌‌​⁠​‌​⁠​​​⁠​‌​⁠​​​‍​‍​‍⁠​​‍​‍‌‍‍​​‍​‍​⁠‍‍​‍​‍‌⁠‌⁠‌‌​‍‌⁠‍​‌‌⁠⁠‌‌​‌‌​⁠⁠‌‍‍‌‌‌‍​‌⁠‌⁠‌⁠​​‌‌​⁠‌‍⁠⁠‌‌⁠⁠‌‍‍​‌⁠‌⁠‌‍​‍​‍​‍‌⁠⁠‌

Prototype 60–80 time-to-event in simsurv + targets for ‘delayed effects’ and 2:1 (CRAN: Package simsurv); specify hazards carefully, @jacwils.

‌⁠‍⁠​‍​‍‌⁠‌​​‍​‍​⁠‍‍​‍​‍‌‍‌⁠‌‍​⁠‌⁠​‍‌‍‍‍​‍​‍​‍⁠​​‍​‍‌‍‍⁠​‍​‍​⁠‍‍​‍​‍‌⁠​‍‌‍‌‌‌⁠​​‌‍⁠​‌⁠‍‌​‍​‍​‍⁠​​‍​‍‌‍‍‌‌‍‌​​‍​‍​⁠‍‍​⁠‍‌​⁠‌​​⁠‌‌​⁠‌​​‍⁠​​‍​‍‌‍‌​​‍​‍​⁠‍‍​‍​‍​⁠​‍​⁠​​​⁠​‍​⁠‌‌​⁠​‌​⁠​​​⁠​‌​⁠‌⁠​‍​‍​‍⁠​​‍​‍‌‍‍​​‍​‍​⁠‍‍​‍​‍‌‍⁠‍‌‍⁠‌‌​‍‍‌​‌​‌‌‌‌‌‍‌‍‌‌​​‌‍⁠⁠‌‍‍‍‌‌​​‌⁠‌‌‌‍⁠‌​⁠​​‌⁠​​‌​⁠‌‌‍⁠‍​‍​‍‌⁠⁠‌

Quick tip: for your ‘60–80’ with 2:1 and a TTE endpoint, I’ve had good luck using flexsurv::rpexp to impose late separation via a piecewise hazard and then fanning out entry-rate/attrition scenarios in parallel with furrr to stabilize OC estimates; see CRAN: Package flexsurv. Small caveat: if you’re layering a Bayesian rule, do a prior predictive calibration first because even weak priors can bite at this size — want a minimal template?

‌⁠‍⁠​‍​‍‌⁠‌​​‍​‍​⁠‍‍​‍​‍‌‍‌⁠‌‍​⁠‌⁠​‍‌‍‍‍​‍​‍​‍⁠​​‍​‍‌‍‍⁠​‍​‍​⁠‍‍​‍​‍‌⁠​‍‌‍‌‌‌⁠​​‌‍⁠​‌⁠‍‌​‍​‍​‍⁠​​‍​‍‌‍‍‌‌‍‌​​‍​‍​⁠‍‍​⁠‍‌​⁠‌​​⁠‌‌​⁠‌​​‍⁠​​‍​‍‌‍‌​​‍​‍​⁠‍‍​‍​‍​⁠​‍​⁠​​​⁠​‍​⁠‌‌​⁠​‌​⁠​​​⁠​‍​⁠​​​‍​‍​‍⁠​​‍​‍‌‍‍​​‍​‍​⁠‍‍​‍​‍‌​⁠‍‌‍‍⁠‌​‍​‌‍⁠‌‌​‌‍‌‍‍​‌​‌‍​‍⁠‌‌‌​‍​⁠‌‌​⁠‍​​⁠‌⁠​⁠‌‌‌‌​‌‌⁠​‍​⁠​‌​‍​‍‌⁠⁠‌