'How to create a scatter plot in excel based on time?
I have the following type of
Date Time Donuts Coffee
1/2/2021 12:00am 2 3
1/3/2021 4:00 am 6 7
2/11/2022 11:00 am 3 2
And what I want is scatter plot I basically my x axis is the dates I have the y axis is my time in 24 hour [0,1,2,3,4,5,6,7,...,24] and I want the graph to say on this date and on this time I ate 2 donuts and drank 3 coffees but I am not sure how to this.
Solution 1:[1]
Little tricky and perhaps other ways to accomplish this. First I removed the Date header. Then I created a scatter plot using just the date and time columns.
Next, click on a graphed dot and select "Add Data Labels". This will label the times. Don't worry about that yet. Then create column E, which is what you are going to label as each dot.
Cell E2 formula: =CONCAT(C2," donuts, ",D2," coffee")
Drag down the formula.
Next, right-click on one of your time labels and select Format Data Labels. In the Format Labels frame on the right, select the box for "Value from Cells". Then select your cell range (E2:E4). Lastly, de-select the y-value box and arrange your label placement as desired.
NOTE: Older versions of Excel may not have the "Value from Cells" label option. Not sure how to work around that limitation.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 |


