The product space method for model-averaging
RoBMA implements Bayesian model-averaging using the product space method
carlin1995bayesian,lodewyckx2011tutorialRoBMA. Rather than fitting
each model separately and combining results after the fitting is complete,
this approach embeds all competing models within a single joint model space.
A discrete model indicator variable selects which model component is "active"
at each MCMC iteration, and the posterior probability of each model is estimated
from the proportion of iterations spent in that model's subspace.
This is achieved by specifying mixture priors that combine:
Null hypothesis component(s): Typically point masses (spikes) representing
the absence of an effect, heterogeneity, or publication bias
Alternative hypothesis component(s): Continuous distributions representing
the presence of the parameter
The mixture structure enables direct computation of:
Inclusion Bayes factors: Evidence for the presence vs. absence of each
parameter (e.g., effect, heterogeneity, bias)
Model-averaged estimates: Posterior estimates that account for model
uncertainty by weighting across all models
Conditional estimates: Posterior estimates given that a particular
hypothesis is true
Default mixture prior structure
By default, RoBMA creates the following mixture priors:
| Parameter | Null component | Alternative component |
| Effect (\(\mu\)) | Spike(0) | Normal(0, UISD-scaled) |
| Heterogeneity (\(\tau\)) | Spike(0) | Normal+(0, UISD-scaled) |
| Publication bias | No bias (prior_none) | Weight functions + PET + PEESE |
| Allocation (\(\rho\)) | (none by default) | Beta(1, 1) |
See prior_specification for details on how the UISD scaling is determined.
Specifying custom mixture priors
Single prior vs. list of priors
Each prior_* and prior_*_null argument accepts either a single prior or a list:
Single prior: Creates one component in the mixture
List of priors: Creates multiple components, enabling model-averaging
across different prior specifications (e.g., different effect size scales)
When multiple priors are specified in a list, they are all treated as alternative
(or null) hypothesis components for the main inclusion Bayes factor. The inclusion
Bayes factor tests the combined evidence for all alternative components against all
null components. The detailed summary output shows posterior probabilities and
inclusion Bayes factors for each individual component separately, allowing finer-grained
inference about which specific prior specification is most supported by the data.
Omitting hypothesis components
For top-level mixture components, setting a prior argument to NULL or FALSE
removes that hypothesis component:
prior_effect_null = NULL: No null hypothesis for effect (assumes effect exists)
prior_effect = NULL: No alternative hypothesis (assumes no effect)
prior_bias_null = NULL or FALSE: No "no bias" model (assumes some bias mechanism)
prior_bias = NULL or FALSE: No bias model (assumes no bias mechanism)
For moderator and scale regression terms, an omitted or whole-argument NULL
prior_mods / prior_scale means "use defaults". To omit a component for a
specific term, use a named list entry such as prior_mods_null = list(x1 = NULL).
Parameter-specific customization for moderators
For moderator priors (prior_mods, prior_mods_null), you can specify different
priors for different predictors using named lists. A single prior object applies
to all moderator terms:
RoBMA(...,
mods = ~ x1 + x2,
prior_mods_null = list(x1 = NULL) # No null for x1, default null for x2
)
This allows testing whether specific moderators have effects while assuming others
are always included or excluded.
Mixture priors for different parameter types
Effect size (\(\mu\)) and heterogeneity (\(\tau\))
Effect and heterogeneity priors combine spike-and-slab components:
# Default: spike(0) null + normal alternative
# Custom: multiple alternatives with different scales
RoBMA(...,
prior_effect = list(
prior("normal", list(mean = 0, sd = 0.5)),
prior("normal", list(mean = 0, sd = 1.0))
)
)
Publication bias
Bias priors combine different publication bias adjustment mechanisms:
No publication bias (null hypothesis)
Weight functions: Selection models with different step functions
PET/PEESE: Regression-based bias adjustment
The model_type argument provides convenient presets:
RoBMA(..., model_type = "PSMA") # Full ensemble (default)
RoBMA(..., model_type = "PP") # Only PET-PEESE models
See publication_bias_prior_specification for the bias-prior
constructors and preset model spaces.
Heterogeneity allocation (\(\rho\)) for multilevel models
When cluster is specified, \(\rho\) controls the cluster-level variance
allocation. The decomposition is
\(\tau_{between} = \tau\sqrt{\rho}\) and
\(\tau_{within} = \tau\sqrt{1 - \rho}\). By default, only an alternative
(Beta(1,1)) is specified, but null hypotheses can be added:
RoBMA(...,
cluster = study,
prior_heterogeneity_allocation_null = prior("spike", list(location = 0.5))
)
Moderator and scale regression terms
When mods is specified, the effect prior becomes the intercept prior, and each
moderator receives a mixture prior. The intercept inherits the effect mixture
structure, while regression coefficients get separate spike-and-slab mixtures.
Similarly, when scale = ~ ... is specified for location-scale models, the
heterogeneity prior becomes the scale intercept prior, and each scale predictor
receives a mixture prior following the same pattern as moderator terms.
Note that the scale intercept (i.e., baseline heterogeneity) is always positive and
the multiplicative scale coefficients require non-zero prior distribution on the
intercept.
Model weights and prior odds
Each component in a mixture prior has an associated prior weight (prior model
probability). User-specified components receive equal weights unless their
prior objects set prior_weights. Publication-bias presets use fixed weights:
"2w" and "6w" split the alternative bias mass equally across their
weight functions, "PP" splits it equally across PET and PEESE, and "PSMA"
assigns half of the alternative bias mass to the six weight functions
combined and one quarter each to PET and PEESE. Custom weights can be
specified via the prior_weights argument in individual prior objects.
The prior odds between null and alternative hypotheses affect the Bayes factor
interpretation. With equal prior weights on null and alternative, the posterior
odds equal the Bayes factor.