Closed
Description
Describe the bug
Function plot_series
has side-effects as y
forgets index name after calling plot_series
. Probably it can be fixed by simply adding a y = y.copy()
to the function.
To Reproduce
from sktime.datasets import load_airline
from sktime.utils.plotting import plot_series
y = load_airline()
y = y.to_frame()
y_name1 = y.index.name
plot_series(y)
y_name2 = y.index.name
assert y_name1 == y_name2
Expected behavior
Additional context
Versions
'0.15.0'