I have the following pandas dataframe, which consist of datetime timestamps and user ids:
id datetime
130 2018-05-17 19:46:18
133 2018-05-17 20:59:57
131 2018-05-17 21:54:01
142 2018-05-17 22:49:07
114 2018-05-17 23:02:34
136 2018-05-18 06:06:48
324 2018-05-18 12:21:38
180 2018-05-18 12:49:33
120 2018-05-18 14:03:58
120 2018-05-18 15:28:36
How can I plot on the y axis the id and on the x axis day or minutes? I tried to:
plt.plot(df3['datatime'], df3['id'], '|')
plt.xticks(rotation='vertical')
However, I have two problems, my dataframe is quite large and I have multiple ids, the second problem is that I wasn't able to arrange each label on the y axis and plot it against its datime value in the x axis. Any idea of how to do something like this:
The whole objective of this plot is to visualize the logins per time of that specific user.