
One-stage and two-stage models for binary outcomes
Source:vignettes/one-stage-two-stage-binary-jackson.qmd
Introduction
Meta-analyses of binary outcomes (events vs. non-events) can be conducted using either a two-stage or a one-stage approach. The distinction matters when studies are small, baseline event rates vary widely, or the outcome is rare.
Two-stage: each study is first summarised to a log-scale effect estimate and standard error , then the meta-analysis uses a Gaussian likelihood on those summaries. This is the default in bayesma and adequate for most applications.
One-stage: the original binomial counts are modelled directly, avoiding the normal approximation and handling studies with zero events without continuity corrections. bayesma implements the one-stage model following Jackson et al. (2018).
Two-stage binary meta-analysis
Effect size computation
For study with treatment arm and control arm , the log odds ratio is
with approximate variance
Log-risk ratios and risk differences are supported via the effect_measure argument.
Meta-analysis model
The two-stage random-effects model applies the standard Gaussian hierarchy to the log-scale summaries:
See Gaussian Random-Effects Model for full details.
Limitations
- The normal approximation to the log-OR is poor when cell counts are small ().
- Studies with zero events require a continuity correction, which shifts the estimate in ways that depend on the correction chosen.
- Within-study information about baseline event rates is discarded.
One-stage model (Jackson et al.)
The one-stage model replaces the Gaussian approximation with an exact binomial likelihood. The formulation follows Jackson et al. (2018).
Model specification
For study and arm :
where is the study-specific log-odds on control (baseline log-odds) and is the study-specific log-odds ratio.
Treatment effects are exchangeable across studies:
Baseline log-odds receive weakly informative priors:
covering a wide range of baseline event rates on the logit scale.
Priors
These match the defaults for the two-stage model. See Prior Predictive Checks for outcome-specific guidance.
Why the one-stage model handles zero events
A study with contributes a valid binomial log-likelihood term — the probability is defined and informative. The nuisance parameters are integrated out by MCMC, so uncertainty about baseline risk propagates into the posteriors for and .
Fitting in bayesma
#| eval: false
# Two-stage (default for binary outcomes with pre-computed summaries)
fit_2s <- bayesma(
data,
outcome = "binary",
effect_measure = "log_or",
model_stage = "two_stage"
)
# One-stage (Jackson et al.) — expects raw count columns r1, n1, r0, n0
fit_1s <- bayesma(
data,
outcome = "binary",
effect_measure = "log_or",
model_stage = "one_stage"
)
summary(fit_1s)When to prefer the one-stage model
| Situation | Recommendation |
|---|---|
| Large studies, moderate event rates | Two-stage is adequate |
| One or more studies have zero events | One-stage preferred |
| Small or sparse data | One-stage preferred |
| Baseline event rates vary substantially | One-stage preferred |
| Computational speed matters | Two-stage is faster |
For most systematic reviews with reasonably sized studies and no zero-event cells, the two approaches yield very similar estimates.
Comparing estimates
#| eval: false
compare_models(fit_2s, fit_1s, labels = c("Two-stage", "One-stage"))Non-trivial differences between the two approaches indicate that the normal approximation is influencing the two-stage result. In that case, the one-stage estimate should be reported as the primary analysis.
References
Jackson D, Law M, Stijnen T, Viechtbauer W, White IR (2018). A comparison of 7 random-effects models for meta-analyses that estimate the summary odds ratio. Statistics in Medicine, 37(7), 1059–1085.