scippneutron.chopper.filtering.collapse_plateaus#
- scippneutron.chopper.filtering.collapse_plateaus(plateaus, *, coord='time')[source]#
Merge plateaus bins into dense data.
Useful for post-processing the result of
scippneutron.chopper.find_plateaus
. Averages the bins and turns the given event coordinate into a bin-edge coordinate.- Parameters:
- Returns:
DataArray
– Dense data with one element per plateau.
See also
scippneutron.chopper.filtering.find_plateaus
Function to construct suitable input data.