Skip to content

Add stl_plot #575

Merged
merged 5 commits into from
Mar 2, 2022
Merged

Add stl_plot #575

merged 5 commits into from
Mar 2, 2022

Conversation

Mr-Geekman
Copy link
Contributor

@Mr-Geekman Mr-Geekman commented Feb 28, 2022

IMPORTANT: Please do not create a Pull Request without creating an issue first.

Before submitting (must do checklist)

  • Did you read the contribution guide?
  • Did you update the docs? We use Numpy format for all the methods and classes.
  • Did you write any new necessary tests?
  • Did you update the CHANGELOG?

Type of Change

  • Examples / docs / tutorials / contributors update
  • Bug fix (non-breaking change which fixes an issue)
  • Improvement (non-breaking change which improves an existing feature)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Proposed Changes

Look #550.

Related Issue

#550.

Closing issues

Closes #550.

@Mr-Geekman Mr-Geekman added the enhancement New feature or request label Feb 28, 2022
@Mr-Geekman Mr-Geekman self-assigned this Feb 28, 2022
@Mr-Geekman
Copy link
Contributor Author

Example of plot

import pandas as pd
import matplotlib.pyplot as plt

from etna.datasets import TSDataset
from etna.analysis import stl_plot


df = pd.read_csv("examples/data/example_dataset.csv")
df = TSDataset.to_dataset(df)
ts = TSDataset(df, freq="D")

stl_plot(ts=ts, in_column="target", period=7)
plt.savefig("plot.png")

The result:
plot

@codecov-commenter
Copy link

codecov-commenter commented Feb 28, 2022

Codecov Report

Merging #575 (b04c801) into master (1920257) will decrease coverage by 32.87%.
The diff coverage is 20.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master     #575       +/-   ##
===========================================
- Coverage   87.21%   54.34%   -32.88%     
===========================================
  Files         119      119               
  Lines        5704     5739       +35     
===========================================
- Hits         4975     3119     -1856     
- Misses        729     2620     +1891     
Impacted Files Coverage Δ
etna/analysis/eda_utils.py 19.11% <17.64%> (-0.50%) ⬇️
etna/analysis/__init__.py 100.00% <100.00%> (ø)
etna/commands/__init__.py 0.00% <0.00%> (-100.00%) ⬇️
etna/commands/backtest_command.py 0.00% <0.00%> (-96.43%) ⬇️
etna/commands/forecast_command.py 0.00% <0.00%> (-92.00%) ⬇️
etna/commands/__main__.py 0.00% <0.00%> (-87.50%) ⬇️
etna/commands/resolvers.py 0.00% <0.00%> (-80.00%) ⬇️
etna/analysis/outliers/density_outliers.py 22.44% <0.00%> (-75.52%) ⬇️
etna/datasets/datasets_generation.py 26.47% <0.00%> (-73.53%) ⬇️
etna/transforms/timestamp/time_flags.py 27.02% <0.00%> (-72.98%) ⬇️
... and 70 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1920257...b04c801. Read the comment docs.

@martins0n martins0n self-requested a review March 1, 2022 07:45
martins0n
martins0n previously approved these changes Mar 2, 2022
Copy link
Contributor

@martins0n martins0n left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@martins0n martins0n enabled auto-merge (squash) March 2, 2022 07:20
@martins0n martins0n merged commit a8fcfa3 into master Mar 2, 2022
@iKintosh iKintosh deleted the issue-550 branch March 22, 2022 08:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add STLplot
3 participants