Skip to main content

Module rebin

Module rebin 

Source
Expand description

Rebinning: coarsen the TOF axis by an integer factor.

Counts in adjacent bins are summed, and the merged bins keep every factor-th edge. Rebinning needs bin edges: a merged bin’s position depends on the widths of the bins it merges, which centres do not give.

Functions§

rebin_counts
Rebin a 3D counts array along axis 0 by summing groups of factor slices.
rebin_edges
Rebin bin edges by keeping every factor-th edge, always including the final edge.