trialr: Bayesian Clinical Trial Designs in R and Stan
Pith reviewed 2026-05-25 13:06 UTC · model grok-4.3
The pith
The trialr package implements Bayesian clinical trial methods in Stan and R with emphasis on posterior sample access.
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
Core claim
The trialr package implements the continual reassessment method, EffTox, and augmented binary method in Stan and R. The key benefit is access to posterior samples that support flexible inference and powerful visualisation in clinical trial settings.
What carries the argument
Access to posterior samples from the Stan models, which enables flexible inference and visualisation.
If this is right
- Users gain the ability to compute custom posterior probabilities for dose selection decisions.
- Visualisations of posterior distributions can display uncertainty around trial outcomes and dose choices.
- The package supports Bayesian analysis of phase I and II oncology trials without requiring users to write Stan code.
- Joint modeling of efficacy and toxicity becomes straightforward through the shared posterior samples.
Where Pith is reading between the lines
- The package could integrate with other R tools for simulating trial performance under different designs.
- Standardized posterior-based reporting might support clearer communication of results to trial oversight committees.
- Adding more trial designs to the package would extend its use to additional adaptive trial scenarios.
Load-bearing premise
The package implementations of the three methods are correct and access to posterior samples delivers the claimed benefits of flexible inference and visualisation.
What would settle it
A side-by-side comparison of trialr outputs against an independent implementation of the continual reassessment method on the same dataset that yields inconsistent dose recommendations or posterior summaries.
read the original abstract
This manuscript introduces an \proglang{R} package called \pkg{trialr} that implements a collection of clinical trial methods in \proglang{Stan} and \proglang{R}. In this article, we explore three methods in detail. The first is the continual reassessment method for conducting phase I dose-finding trials that seek a maximum tolerable dose. The second is EffTox, a dose-finding design that scrutinises doses by joint efficacy and toxicity outcomes. The third is the augmented binary method for modelling the probability of treatment success in phase II oncology trials with reference to repeated measures of continuous tumour size and binary indicators of treatment failure. We emphasise in this article the benefits that stem from having access to posterior samples, including flexible inference and powerful visualisation. We hope that this package encourages the use of Bayesian methods in clinical trials.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. This manuscript introduces an R package called trialr that implements a collection of clinical trial methods in Stan and R. In this article, we explore three methods in detail. The first is the continual reassessment method for conducting phase I dose-finding trials that seek a maximum tolerable dose. The second is EffTox, a dose-finding design that scrutinises doses by joint efficacy and toxicity outcomes. The third is the augmented binary method for modelling the probability of treatment success in phase II oncology trials with reference to repeated measures of continuous tumour size and binary indicators of treatment failure. We emphasise in this article the benefits that stem from having access to posterior samples, including flexible inference and powerful visualisation.
Significance. If the Stan implementations faithfully reproduce the published likelihoods and priors, the package would provide a practical tool for applying these Bayesian designs, with the claimed advantages of posterior samples enabling flexible post-hoc inference and visualization not easily available in point-estimate or MCMC-black-box alternatives.
major comments (1)
- [Sections describing the Stan models for CRM, EffTox, and augmented binary] The central claim that trialr correctly implements CRM, EffTox, and the augmented binary method (and thereby delivers the stated benefits of posterior samples) rests on an unverified assumption of implementation fidelity. No simulation benchmarks against known analytic results, no comparisons to existing packages (e.g., dfcrm), and no posterior predictive checks on published datasets are reported anywhere in the manuscript.
Simulated Author's Rebuttal
We thank the referee for their review and the opportunity to respond. We address the single major comment below.
read point-by-point responses
-
Referee: [Sections describing the Stan models for CRM, EffTox, and augmented binary] The central claim that trialr correctly implements CRM, EffTox, and the augmented binary method (and thereby delivers the stated benefits of posterior samples) rests on an unverified assumption of implementation fidelity. No simulation benchmarks against known analytic results, no comparisons to existing packages (e.g., dfcrm), and no posterior predictive checks on published datasets are reported anywhere in the manuscript.
Authors: We agree that the manuscript does not report simulation benchmarks, comparisons to packages such as dfcrm, or posterior predictive checks, and that this leaves the claim of implementation fidelity unverified in the text. The Stan models are presented as direct implementations of the published likelihoods and priors, with the package source available for inspection, but we acknowledge that explicit validation would strengthen the paper. In the revised manuscript we will add a dedicated validation section that includes (i) comparison of CRM dose recommendations against the dfcrm package on standard examples and (ii) posterior predictive checks on the published datasets referenced in the EffTox and augmented-binary sections. revision: yes
Circularity Check
No circularity: software description of existing methods
full rationale
The paper introduces the trialr R package implementing standard Bayesian designs (continual reassessment method, EffTox, augmented binary) in Stan and R. It references these as established methods without presenting new derivations, predictions, or equations that reduce to fitted inputs or self-citations. Emphasis on posterior sample benefits is conceptual and does not involve any self-definitional, fitted-input, or ansatz-smuggling steps. No load-bearing self-citation chains or uniqueness theorems are invoked. The manuscript is self-contained as a software description against external benchmarks of the cited methods.
discussion (0)
Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.