h5analysis.simplemath.bin_shape_1d

h5analysis.simplemath.bin_shape_1d(arr, width)

Bins 1d arrays by truncating the array at the end if necessary and calculating the mean in each bin

Parameters:
  • arr (numpy array) – 1d array with data to be binned

  • width (int) – Binsize, how many data points per bin

Returns:

arr – Binned 1d data

Return type:

numpy array