This might be similar to this problem but mine is in the context of plot_date.
UPDATE
log = row[3]
day = log.strftime("%Y%m%d")
month = log.strftime("%m")
month2 = log.strftime("%B")
year = log.strftime("%y")
times = to_seconds(log.strftime("%I:%M"))
log
is from the database records in 2016-10-28 20:53:26
format.
time3 =[29100.0, 28860.0, 29280.0, 37980.0, 29100.0, 24780.0, 29700.0, 29160.0, 29460.0, 29100.0, 28980.0, 33780.0, 29400.0, 29100.0, 29400.0, 30360.0, 6180.0, 28860.0, 29400.0, 4440.0, 29160.0, 29160.0]
day3 = ['20161003', '20161004', '20161005', '20161006', '20161007', '20161009', '20161010', '20161011', '20161012', '20161013', '20161014', '20161017', '20161018', '20161019', '20161020', '20161021', '20161023', '20161024', '20161025', '20161026', '20161027', '20161028']
plt.grid(True, which='both')
plt.grid(b=True, which='major', color='k', linestyle='-')
plt.grid(b=True, which='minor', color='k', linestyle='-', linewidth=0.1)
plt.xticks(rotation='vertical',fontsize='small')
plt.minorticks_on()
plt.margins(0.01)
plt.plot_date(x=day3,y=time3,color="red", linestyle='--', markersize=4)
plt.ylabel("Time")
plt.xlabel("Day")
attached is the sample output:
I want to display the y-axis in H:m format.