plot_re_acceptance_stacked¶
- jaxrens.postprocess.plotting.plot_re_acceptance_stacked(monitor_or_trace, *, ax=None, window=None, pair_labels=None, cmap='viridis', raw_alpha=0.3, raw_lw=0.5, smooth_lw=1.5, offset_scale=1.0)[source]¶
Plot per-pair RE swap acceptance with vertical stacking.
Each adjacent-pair acceptance trace is shifted vertically by
p * offset_scaleso overlapping curves do not crowd a single [0, 1] band. A faint raw line is overlaid by a boxcar-smoothed line in the same color; black baselines mark each pair’s zero. A right-hand twin axis carries the pair labels.Mirrors the legacy
jaxnest.plot.plot_output.plot_acc_ratesstyle.- Parameters:
monitor_or_trace – Populated Monitor with a non-None
re_traceor anRELogdirectly.ax (Axes | None) – Existing axes to plot into. Created if None.
window (int | None) – Optional boxcar smoothing window length (in fire entries). Defaults to
max(1, n_entries // 50).pair_labels (list[str] | None) – Optional per-pair labels for the right-hand twin axis. Length must equal
n_pairs. Defaults to"p↔p+1".cmap (str) – Colormap name used to color the per-pair curves.
raw_alpha (float) – Alpha for the raw (unsmoothed) curves.
raw_lw (float) – Linewidth for the raw curves.
smooth_lw (float) – Linewidth for the smoothed overlay.
offset_scale (float) – Vertical separation between pairs in [0, 1] units.
- Returns:
The left Axes object (the right twin can be retrieved via
ax.figure.axes[-1]).- Return type:
Axes