Plotting

moabbr.plots.ranking_plot(data: dict) Figure

Horizontal bar chart of treatment rankings.

Parameters:

  • data: Result dict from tombolo.nma or tombolo.bnma.

Returns treatments sorted by rank score (P-score for NMA, SUCRA for BNMA).

moabbr.plots.league_table(data: dict) Figure

Grid of pairwise treatment comparisons.

Parameters:

  • data: Result dict from tombolo.nma or tombolo.bnma.

Each cell shows the mean difference and confidence (or credible) interval for the row treatment relative to the column treatment. The contrast is row minus column. Diagonal cells show the treatment name. P-values are included for NMA results.

moabbr.plots.forest_plot(data: dict, reference: str) Figure

Forest plot of all treatments relative to a reference.

Parameters:

  • data: Result dict from tombolo.nma or tombolo.bnma.

  • reference: Name of the reference treatment. All other treatments are plotted relative to it, sorted by effect size. Non-alphanumeric characters are normalized to underscores.

Returns mean differences and confidence (or credible) intervals for each treatment versus the reference. P-values are included for NMA results.

Raises RuntimeError if reference is not found in the data.

moabbr.plots.heterogeneity_table(data: dict) Figure

Summary table of heterogeneity statistics.

Parameters:

  • data: Result dict from tombolo.nma or tombolo.bnma.

For NMA results: Q statistic, p-value, I², and τ. For BNMA results: posterior SD and 95% credible interval.

moabbr.plots.prediction_table(data: dict) Figure

Grid of prediction intervals. Only applicable to NMA results.

Parameters:

  • data: Result dict from tombolo.nma.

Each cell shows the 95% prediction interval for the row treatment relative to the column treatment.

moabbr.plots.convergence_table(data: dict) Figure

Summary table of MCMC convergence diagnostics. Only applicable to BNMA results.

Parameters:

  • data: Result dict from tombolo.bnma.

Returns R-hat (max), ESS bulk (min), and ESS tail (min) across all model parameters.