Plotting the data in a time-series manner for multiple attributes

时间:2018-01-15 18:08:05

标签: python pandas jupyter-notebook

I am trying to visualize the data in Jupyter notebook based in the shape of time-series. The data is representing the sales of a store for each month of years 2013, 2014 and 2015. So, each year should be represented by a line, where x axis is the months and y axis shows the sales. Even though, I can select the data in a table, I have difficulties plotting them on a time-series chart. What is the best way to actually plot this data in Jupyter notebook?

The data looks like the following:

enter image description here

1 个答案:

答案 0 :(得分:3)

尝试:

monthlySales['sales'].unstack().plot()

enter image description here

相关问题