Skip to contents

Creates overlaid histograms of marginal energy and energy transition, along with the E-BFMI statistic. Low E-BFMI indicates poor exploration of the posterior.

Usage

plot_energy(fit)

Arguments

fit

A ratiod_fit object (HMC backend).

Value

A ggplot object (if ggplot2 available) or base R plot.

Details

E-BFMI (Energy Bayesian Fraction of Missing Information) compares the distribution of energy levels to energy transitions. Values below 0.3 indicate the sampler may not be exploring the full posterior.

Examples

# See plot_rhat() examples for fitting a model
# plot_energy(fit)