[BUG] TimeSeries.plot() not showing plot
See original GitHub issueDescribe the bug When creating a TimeSeries “ts” object and trying to plot it with ts.plot() no plot is showing up. I am running the code snippet below in a Jupyter Notebook.
To Reproduce
df = pd.DataFrame(data={'First': [0,1,2,3,4,4.5,4,3,2,1]}))
inds = [f'2021-01-{day}' for day in range(1, 11)]
df.index = pd.to_datetime(inds)
ts = TimeSeries.from_dataframe(df)
ts.plot()
Expected behavior A plot showing the values of my component “First”
System:
- Python version: [e.g. 3.7.5]
- darts version [e.g. 0.9.1]
Additional context
I fixed the issue with a overwriting of the TimeSeries.plot()
function and adding a plt.show()
There is a big chance that I just use the functions wrong, since I am a very new user to the library.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
BUG: strange timeseries plot behavior · Issue #6608 - GitHub
@rosnfeld so this occurs when you have multiple series overlaid on the same plot and 1 is converted to PeriodIndex for display while...
Read more >Time series plot not showing as desired in R - Stack Overflow
I have two columns that I want to make a time series plot from. ... The output plot is not what I expected,...
Read more >Fixing common date annoyances - Matplotlib
Now when you hover your mouse over the plotted data, you'll see date format strings like 2004-12-01 in the toolbar. plt.show() Copy to...
Read more >Bokeh not displaying graph - Problems and bugs
from bokeh.plotting import figure, output_notebook, show # prepare some data x = [1, 2, 3, 4, 5] y = [6, 7, 2, 4,...
Read more >Work With Datetime Format in Python - Time Series Data
Bar plot showing daily precipitation with the x-axis dates as datetimes. Note: you do not need to use .values when using an index...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Just a quick update:
Reinstalling the ipykernel fixed the issue.
I will now walk away in embarrassment.
I faced a similar issue with the plotting function. I found that adding
%matplotlib inline
would solve the problem.