hist.tag module#

class hist.tag.Locator(offset: int = 0)#

Bases: object

NAME = ''#
offset#
class hist.tag.at(value: int)#

Bases: object

value#
class hist.tag.loc(value: str | float, offset: int = 0)#

Bases: Locator

value#
class hist.tag.rebin(factor_or_axis: int | PlottableAxis | None = None, /, *, factor: int | None = None, groups: Sequence[int] | None = None, edges: Sequence[int | float] | None = None, axis: PlottableAxis | None = None)#

Bases: object

axis#
axis_mapping(axis: PlottableAxis) tuple[Sequence[int], PlottableAxis | None]#
edges#
factor#
group_mapping(axis: PlottableAxis) Sequence[int]#

Return the list of group sizes (numbers of adjacent bins to merge) for axis. For explicit groups, the sum of the group sizes must equal the number of bins in the axis. For a factor, this returns len(axis) // factor groups of size factor; if the factor does not divide the number of bins evenly, the leftover bins are not part of any group (a consumer should merge them into the overflow bin, matching the C++ factor-based rebinning).

groups#
hist.tag.sum(iterable, /, start=0)#

Return the sum of a ‘start’ value (default: 0) plus an iterable of numbers

When the iterable is empty, return the start value. This function is intended specifically for use with numeric values and may reject non-numeric types.