How can I draw a graph like this in a computer program?
Solution 1:
This can be easily accomplished in Excel. All you need to do is use your data to create an XY/Scatter Chart and then format as appropriate. Using the Scatter Chart, your horizontal values will be proportionally accurate. You can also use vertical error bars to replace your markers (dots). And Excel now allows you to use a range of cells for labels, so you can have your Event labels (or whatever else you choose) as part of the chart. You can also completely remove the vertical axis if you'd like (since it's redundant).
-
Create your data table (i.e. an Excel table, created using
Insert>Tables>Table
). -
Create a blank XY/Scatter chart (do this by
Insert>Charts>Scatter
while you have a blank cell on the worksheet selected) -
Select data for your chart (with chart selected, right-click and choose
Select Data
from context menu). Name: Anything you like
Series X: your X column
Series Y: your Y column -
Format as desired. To match your sample, I did the following: Changed Y axis (removed labels, changed max value)
Changed X axis (removed labels)
Changed series (add data labels, add vertical error bars (for lines), turn off markers) -
Here's the final version:
Solution 2:
Could you provide a sample about your problem?
In Excel Chart, you can use Data Labels to help display values: