I have dataframe with dates and hours, for every hour (0 - 23) I have data for the corresponding date (2016-11-07 - 2016-11-27):
2016-11-07 2016-11-08 2016-11-09 2016-11-10 2016-11-11 2016-11-12 2016-11-13 2016-11-14 2016-11-15 2016-11-16
0 0.000000 1014.947022 1013.127572 1009.481264 1012.850683 1013.877889 1011.521497 1012.648708 1010.455797 1009.721842
1 0.000000 1014.506025 1012.941925 1009.152700 1013.012786 1013.631267 1011.343978 1012.562133 1010.289586 1009.614408
2 0.000000 1014.486303 1012.504753 1009.176406 1012.993172 1013.223181 1011.321553 1012.367675 1010.254122 1009.324017
I'm plotting a colormap of the data like this:
fig, ax = plt.subplots(figsize=(40, 20))
ax.imshow(df5, origin='lower', cmap='viridis')
plt.show()
How can I make the x-axis tick labels to be the dates of the original dataframe ? I need a tickmark for every day with the corresponding date. And also for the y tick marks, I want to add tick marks at 9:00, 15:00, 21:00, 3:00 and have a marked horizontal line on those times as well.
Thanks!