OnlineACFPeriodicityDetector#
- class pyriodicity.OnlineACFPeriodicityDetector(window_size, buffer_size=None, window_func='boxcar', detrend_func='linear')#
Online Autocorrelation Function (ACF) based periodicity detector.
Detect periodicities in a signal stream using online ACF. A lag value is considered a period if it is a local maximum of the ACF [1].
- Parameters:
- window_sizeint
Size of the sliding window for the ACF computation.
- buffer_sizeint, optional, default = 2 * window_size
Size of the samples buffer. Must be at least equal to window_size.
- window_funcfloat, str, tuple, optional, default = ‘boxcar’
Window function to apply. See
scipy.signal.get_windowfor accepted formats of thewindowparameter.- detrend_func{‘constant’, ‘linear’}, optional, default = ‘linear’
The kind of detrending to apply. If None, no detrending is applied.
See also
pyriodicity.ACFPeriodicityDetectorAutocorrelation Function (ACF) based periodicity detector.
scipy.signal.get_windowReturn a window of a given length and type.
References
[1]Hyndman, R.J., & Athanasopoulos, G. (2021) Forecasting: principles and practice, 3rd edition, OTexts: Melbourne, Australia. https://OTexts.com/fpp3/acf.html. Accessed on 09-15-2024.
Methods
detect(data[, max_period_count])Update the online ACF and detect periodicities.