Histograms
centers2edges
histogram2d
- apav.core.histogram.histogram2d(x, y, extents, bins)[source]
Calculate two-dimensional histograms by specifying the number of bins.
- Parameters:
x (
ndarray
) – Array 1y (
ndarray
) – Array 2extents (
Tuple
[Tuple
[Number
,Number
],Tuple
[Number
,Number
]]) – (tuple, tuple) designating range to perform mass_histogrambins (
int
) – Number of bins
- Return type:
ndarray
histogram1d
- apav.core.histogram.histogram1d(data, bin_width, rng)[source]
1d mass_histogram that returns array of counts and array of bin centers.
- Parameters:
data (
ndarray
) – data to compute the histogram onbin_width (
Number
) – bin width of the binsrng (
Tuple
[Number
,Number
]) – boundaries of the histogram
- Return type:
Tuple
[ndarray
,ndarray
]
histogram2d_binwidth
- apav.core.histogram.histogram2d_binwidth(x, y, extents, bin_width=0.1)[source]
Calculate two-dimensional histograms by bin width instead of number of bins.
- Parameters:
x (
ndarray
) – Array 1y (
ndarray
) – Array 2extents (
Tuple
[Tuple
[Number
,Number
],Tuple
[Number
,Number
]]) – (tuple, tuple) designating range to perform mass_histogrambin_width (
Number
) – Width of the bins in Daltons
- Return type:
ndarray