edges_analysis.averaging.averaging.get_binned_weights

edges_analysis.averaging.averaging.get_binned_weights(x: ndarray, bins: ndarray, weights: ndarray | None = None) ndarray[source]

Get the total weight in each bin for a given vector.

Parameters:
  • x – The input co-ordinates (1D).

  • bins – The bins into which to bin the x.

  • weights – Array with last dimension the same length as x. Input weights.

Returns:

weights – Output bin weights.