iceplot¶
Advanced histogram visualization functions.
iceplot.iceplot¶
- create_axes(xlabel='$x$', ylabel='Counts', ylabel_ratio='Ratio', xlim=(0, 1), ylim=None, ratio_plot=True, figsize=(5, 4), fontsize=8, units={'x': '', 'y': ''}, **kwargs)[source]¶
Axes creator.
- hist_to_density(counts, errs, bins)[source]¶
Normalize to unit integral density function over the visible histogram range
- hist_to_density_fullspace(counts, errs, bins, totalweight)[source]¶
Normalize histogram to a unit integral density function over total sum of event weights (not just the visible histogram range mass)
- histhepdata(hepdata, all_obs, scale=None, density=False, MC_XS_SCALE=1000000000000.0, label='Data', style={'histtype': 'step', 'ls': '-', 'lw': 1, 'zorder': 0})[source]¶
- histmc(mcdata, all_obs, density=False, scale=None, color=(0, 0, 1), label='none', style={'histtype': 'step', 'ls': '-', 'lw': 1, 'zorder': 0})[source]¶
Over all observables of an MC sample
- ordered_legend(ax=None, order=None, frameon=False, unique=False, **kwargs)[source]¶
Ordered legends.
- plot_horizontal_line(ax, ypos=1.0, color=(0.5, 0.5, 0.5), linewidth=0.9)[source]¶
For the ratio plot
- ratioerr(A, B, sigma_A, sigma_B, sigma_AB=0, EPS=1e-15)[source]¶
Ratio f(A,B) = A/B error, by Taylor expansion of f.
- set_global_style(dpi=120, figsize=(4, 3.75), font='serif', font_size=8, legend_fontsize=7, legend_handlelength=1)[source]¶
Set global plot style.