

Continuing with my uber eats data set, I wanted to see how many orders I placed per month for the past year. This took some time and effort! I thank my AI mentor ChatGPT for helping me through this challenge.
1. Import datetime and matplotlib.
2. I removed the words “UTC” from the Order Time column because I had trouble converting that string into a date time object.
3. Next, I used pd.to_datetime to convert Order Time column into a date time object.
4. I wanted only the month and year data, so I stripped the other data.
5. I used value.counts() to count the orders per month.
6. I added zero values for the first four months of 2023 because there were no orders.
7. I used index.sort() to order the column according to date rather than highest order.
8. Matplotlib to print the graph.
The code I used is in the pdf below.
You must be logged in to post a comment.