Allows plots that compare multiple baggr models that were passed for comparison purposes to baggr compare or run automatically by baggr_compare
# S3 method for baggr_compare
plot(
x,
compare = x$compare,
style = "areas",
grid_models = FALSE,
grid_parameters = TRUE,
prob = x$prob,
hyper = TRUE,
transform = NULL,
order = F,
vline = FALSE,
add_values = FALSE,
values_digits = 2,
values_size = 4,
...
)
baggr_compare model to plot
When plotting, choose between comparison of "groups"
(default), "hyperpars"
(to omit group-specific estimates)
or (predicted) "effects"
.
The "groups"
option is not available when what = "prior"
.
What kind of plot to display (if grid_models = TRUE
),
passed to the style
argument in baggr_plot.
If FALSE
(default), generate a single comparison plot;
if TRUE
, display each model (using individual baggr_plot's)
side-by-side.
if TRUE
, uses ggplot
-style facetting when plotting models
with many parameters (especially "quantiles"
, "sslab"
);
if FALSE
, returns separate plot for each parameter
Width of uncertainty interval (defaults to 95%)
Whether to plot pooled treatment effect
in addition to group treatment effects when compare = "groups"
a function (e.g. exp(), log()) to apply to the values of group (and hyper, if hyper=TRUE) effects before plotting
Whether to sort by median treatment effect by group. If yes, medians from the model with largest range of estimates are used for sorting. If not, groups are shown alphabetically.
logical; show vertical line through 0 in the plot?
logical; if TRUE, values will be printed next to the plot, in a style that's similar to what is done for forest plots
number of significant digits to use when printing values,
size of font for the values, if add_values == TRUE
ignored for now, may be used in the future