Learn R Programming

powerbrmsINLA (version 1.1.1)

plot_bf_heatmap: Plot Bayes Factor Heatmap (mean log10 BF10, Multi-Effect Grid Friendly)

Description

Heatmap of mean log10 BF10 as a function of two effect grid columns (x/y), with optional faceting.

Usage

plot_bf_heatmap(
  power_results,
  x_effect = NULL,
  y_effect = "n",
  facet_by = NULL,
  n = NULL,
  agg_fun = mean,
  title = NULL,
  subtitle = NULL
)

Value

ggplot object.

Arguments

power_results

Simulation results from a brms_inla_power* function with compute_bayes_factor = TRUE.

x_effect

Name of effect grid column for x-axis (default: first grid column).

y_effect

Name of effect grid column for y-axis (default: "n").

facet_by

Optional column(s) to facet by.

n

Optional sample size to filter to (NULL means plot all; else show only that n).

agg_fun

Aggregation function (default: mean).

title, subtitle

Optional plot labels.