Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix doc rendering in statistics.py #2044

Merged
merged 3 commits into from
Nov 1, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 10 additions & 5 deletions darts/utils/statistics.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,13 +150,14 @@ def extract_trend_and_seasonality(
Only compatible with ``ADDITIVE`` model type.
kwargs
Other keyword arguments are passed down to the decomposition method.

Returns
-------
Tuple[TimeSeries, TimeSeries]
A tuple of (trend, seasonal) time series.

References
-------
----------
.. [1] https://www.statsmodels.org/devel/generated/statsmodels.tsa.seasonal.seasonal_decompose.html
.. [2] https://www.statsmodels.org/devel/generated/statsmodels.tsa.seasonal.STL.html
.. [3] https://www.statsmodels.org/devel/generated/statsmodels.tsa.seasonal.MSTL.html
Expand Down Expand Up @@ -248,6 +249,7 @@ def remove_from_series(
Must be ``from darts.utils.utils import ModelMode, SeasonalityMode`` Enums member.
Either ``MULTIPLICATIVE`` or ``ADDITIVE``.
Defaults ``ModelMode.MULTIPLICATIVE``.

Returns
-------
TimeSeries
Expand Down Expand Up @@ -304,10 +306,12 @@ def remove_seasonality(
Defaults to "naive"
kwargs
Other keyword arguments are passed down to the decomposition method.
Returns

Returns
-------
TimeSeries
A new TimeSeries instance that corresponds to the seasonality-adjusted 'ts'.

References
-------
.. [1] https://www.statsmodels.org/devel/generated/statsmodels.tsa.seasonal.seasonal_decompose.html
Expand Down Expand Up @@ -354,6 +358,7 @@ def remove_trend(
Defaults to "naive"
kwargs
Other keyword arguments are passed down to the decomposition method.

Returns
-------
TimeSeries
Expand Down Expand Up @@ -618,7 +623,7 @@ def plot_acf(
axis
Optionally, an axis object to plot the ACF on.
default_formatting
Whether or not to use the darts default scheme.
Whether to use the darts default scheme.

References
----------
Expand Down Expand Up @@ -722,7 +727,7 @@ def plot_pacf(
axis
Optionally, an axis object to plot the ACF on.
default_formatting
Whether or not to use the darts default scheme.
Whether to use the darts default scheme.

References
----------
Expand Down Expand Up @@ -889,7 +894,7 @@ def plot_residuals_analysis(
fill_nan
A boolean value indicating whether NaN values should be filled in the residuals.
default_formatting
Whether or not to use the darts default scheme.
Whether to use the darts default scheme.
acf_max_lag
The maximum lag to be displayed in the ACF plot. Must be less than residuals length.
"""
Expand Down
Loading