pandas .plot() x-axis tick frequency — how can I show more ticks?

后端 未结 4 1840
梦毁少年i
梦毁少年i 2020-12-09 04:44

I am plotting time series using pandas .plot() and want to see every month shown as an x-tick.

Here is the dataset structure

Here is the result of the .plo

4条回答
  •  庸人自扰
    2020-12-09 05:14

    The right way to do that described here Using the x_compat parameter, it is possible to suppress automatic tick resolution adjustment

    df.A.plot(x_compat=True)

提交回复
热议问题