nessai.utils.stats
Utilities related to statistics.
Module Contents
Functions
|
Compute the rolling mean with a given window size. |
- nessai.utils.stats.rolling_mean(x, N=10)
Compute the rolling mean with a given window size.
Based on this answer from StackOverflow: https://stackoverflow.com/a/47490020
- Parameters
- x
numpy.ndarray
Array of samples
- Nint
Size of the window over which the rolling mean is computed.
- x
- Returns
numpy.ndarray
Array containing the moving average.