sweights_u

minkit.sweights_u(a, sweights, bins=10, range=None)[source]

Get the uncertainty associated to the s-weights related to sample a. Arguments are similar to those of numpy.histogram(). By definition, the uncertainty on the s-weights (for plotting), is defined as the sum of the squares of the weights in that bin, like

\[\sigma = \sqrt{\sum_{b \in \delta x} \omega^2}\]
Parameters
Returns

Uncertainties for each bin of the histogram.

Return type

numpy.ndarray