From 2b7edcbbd6a59796fc3fa5d5550953a418a2ad5e Mon Sep 17 00:00:00 2001 From: Iskander Gaba Date: Fri, 25 Oct 2024 02:59:38 +0200 Subject: [PATCH] Tweak dosctrings --- pyriodicity/detectors/acf.py | 4 ++-- pyriodicity/detectors/autoperiod.py | 4 ++-- pyriodicity/detectors/cfd_autoperiod.py | 12 ++++++------ pyriodicity/detectors/fft.py | 8 ++++---- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/pyriodicity/detectors/acf.py b/pyriodicity/detectors/acf.py index 2351a38..7fb5cf0 100644 --- a/pyriodicity/detectors/acf.py +++ b/pyriodicity/detectors/acf.py @@ -26,8 +26,8 @@ class ACFPeriodicityDetector: Examples -------- - Start by loading a timeseries datasets and resampling to an appropriate - frequency. + Start by loading Mauna Loa Weekly Atmospheric CO2 Data from Statsmodels + and downsampling its data to a monthly frequency. >>> from statsmodels.datasets import co2 >>> data = co2.load().data diff --git a/pyriodicity/detectors/autoperiod.py b/pyriodicity/detectors/autoperiod.py index 2d32501..fda6696 100644 --- a/pyriodicity/detectors/autoperiod.py +++ b/pyriodicity/detectors/autoperiod.py @@ -32,8 +32,8 @@ class Autoperiod: Examples -------- - Start by loading a timeseries datasets and resampling to an appropriate - frequency. + Start by loading Mauna Loa Weekly Atmospheric CO2 Data from Statsmodels + and downsampling its data to a monthly frequency. >>> from statsmodels.datasets import co2 >>> data = co2.load().data diff --git a/pyriodicity/detectors/cfd_autoperiod.py b/pyriodicity/detectors/cfd_autoperiod.py index d57f160..86252e3 100644 --- a/pyriodicity/detectors/cfd_autoperiod.py +++ b/pyriodicity/detectors/cfd_autoperiod.py @@ -11,7 +11,7 @@ class CFDAutoperiod: """ CFD-Autoperiod periodicity detector. - Find the periods in a given signal or series using CFDAutoperiod [1]_. + Find the periods in a given signal or series using CFD-Autoperiod [1]_. Parameters ---------- @@ -33,8 +33,8 @@ class CFDAutoperiod: Examples -------- - Start by loading a timeseries datasets and resampling to an appropriate - frequency. + Start by loading Mauna Loa Weekly Atmospheric CO2 Data from Statsmodels + and downsampling its data to a monthly frequency. >>> from statsmodels.datasets import co2 >>> data = co2.load().data @@ -59,9 +59,9 @@ class CFDAutoperiod: >>> cfd_autoperiod.fit(k=300) array([12]) - ``CFDAutoperiod`` is considered a more robust variant of ``Autoperiod``. - The detection algorithm found exactly one periodicity of 12, suggesting - a strong yearly periodicity. + ``CFDAutoperiod`` is considered a more robust variant of ``Autoperiod`` + against noise. The detection algorithm found exactly one periodicity + length of 12, suggesting a strong yearly periodicity. """ def __init__(self, endog: ArrayLike): diff --git a/pyriodicity/detectors/fft.py b/pyriodicity/detectors/fft.py index 8110fe2..c7e6792 100644 --- a/pyriodicity/detectors/fft.py +++ b/pyriodicity/detectors/fft.py @@ -45,10 +45,10 @@ class FFTPeriodicityDetector: 40, 28, 20, 3, 5, 15, 29, 22, 2, 24, 53, 33, 26, 16, 17, 21]) - ``FFTPeriodicityDetector`` tends to be quite sensitive to noise and find - many false period lengths. Depending on your data, you can choose to - apply a window function to get different results. You can also limit the - number returned period length values to the 3 most signficant ones. + ``FFTPeriodicityDetector`` tends to be quite sensitive to noise and can find + many false period lengths. Depending on your data, you can choose to apply + a window function to get different results. You can also limit the number + returned period length values to the 3 most signficant ones. >>> fft_detector.fit(window_func="blackman", max_period_count=3) array([12, 13, 11])