
Make a Graph with Error Bars
A Step by Step Guide to Graphs with Error Bars
Make a Graph with Error Bars
Step 1: Set up the grid
| This is one way you could set up Plotly’s grid to make the graph above (data here: https://plot.ly/~cimar/209 ). | ![]() |
| Select Scatter plot from the MAKE A PLOT menu. You can also add error bars to line plots and bar charts. | ![]() |
| Click the Error bars option in the sidebar. | ![]() |
| Select the column of error values that correspond to your y-values. | ![]() |
| (Alternatives: you can also select error values to correspond to your x-values, or… | ![]() |
| …by selecting the Asymmetric errors option instead, you can set two different sets of error values for each coordinate. “Ey-” sets the length of the bar extending beneath each point, and “Ey” sets the length of the bar extending out from above it.) | ![]() |
| Click the blue plot button in the sidebar to create the chart. (For more help with the grid see: https://plot.ly/add-data-to-the-plotly-grid/ | ![]() |
Step 2: Edit the error bars
| Your plot should look something like this. Open the TRACES popover in the toolbar. | ![]() |
| This is what the Error bars tab of the TRACES popover should look like. We changed the weight of the bars, and made their feet a little wider. | ![]() |
| (Alternative: you can add new error bars to a line plot, scatter plot, or bar chart from the TRACES popover. For example, you can add red error bars to the x-coordinates of every point, and set their length to 4% of the x-coordinate’s value.) | ![]() |
Step 3: Style and annotate!
| Your plot should look something like this. In order to get the graph at the top of the chart, you’ll need to style it. | ![]() |
| This is what the Mode and Style tabs of the TRACES popover should look like for Mean. For more information on styling line and scatter charts, check out: http://help.plot.ly/make-a-line-or-scatter-graph/ | ![]() |
| Here’s how the LAYOUT popover should look. We’ve nudged the top margin, and we’re giving our chart a grey background. We’ve also changed the font. | ![]() |
| This is what the Lines tab of the AXES popover looks like for All Axes. We’ve made the grid lines white. | ![]() |
| We’re hiding the legend in the LEGEND popover. | ![]() |
| Your finished chart should look something like this: | ![]() |















