I'm trying to plot a time series data, where for certain periods there is no data. Data is loaded into dataframe and I'm plotting it using df.plot()
. The problem is that the missing periods get connected while plotting, giving an impression that value exists in that period, while it doesn't.
Here's an example of the problem
There is no data between Sep 01 and Sep 08 as well as between Sep 09 and Sep 25, but the data is plotted in a way that it seems that there are values in that period.
I would like to have zero values visualized in that period, or no values at all. How to do that?
Just to be clear, I don't have NaN values for periods [Sep 01, Sep 08], [Sep 09, Sep 29], but no data at all (not even in the time index).