Rootogram#

Rootogram for the posterior predictive and observed data.

Matplotlib version of plot_ppc_rootogram

Link to this page with the bokeh tab selected

Link to this page with the plotly tab selected

from arviz_base import load_arviz_data

import arviz_plots as azp

azp.style.use("arviz-variat")

dt = load_arviz_data("rugby")
pc = azp.plot_ppc_rootogram(
    dt,
    aes={"color": ["__variable__"]}, # map variable to color
    aes_by_visuals={"title": ["color"]}, # change title's color per variable
    backend="none",
)
pc.show()

See also

API Documentation: plot_ppc_rootogram

EABM chapter on Posterior predictive checks for count data

Other examples with plot_ppc_rootogram#