Show Sidebar Hide Sidebar

Three Y Axes Graph with Plotly and Excel

A Step by Step Guide to Making a Graph with Three Y Axes With Plotly and Excel

Step 1

Upload your Excel data to Plotly's grid

Open the data file for this tutorial in Excel. You can download the file here in CSV format

Excel view

Step 2

Head to Plotly

Head to Plotly's Workspace and sign into your free Plotly account. Go to 'Import', click 'Upload a file', then choose your Excel file to upload. Your Excel file will now open in Plotly's grid. For more about Plotly's grid, see this tutorial

Import data

Step 3

Creating Your Chart

Label your columns like we did below. You'll have three y-axis columns (cost, output, defective) and one x-axis column (date). Select 'Line plots' from the MAKE A PLOT menu and then click line plot in the bottom left.

Labeling

Your plot would initially look something like this.

Original

Head to the TRACES popover and access Col2. Prepare to add the second y-axis. Click 'New Axis/Subplot…'

New Axis

You'll want to apply your new y-axis to the right side of the graph.

Right

Your graph should now look something like this:

Progress

Now, we'll peform a similar process for Col3. Instead of applying third y-axis to the right side of the graph, choose 'free left' instead.

Free Left

Your graph should now look something like this:

Progress1

Step 4

Finalizing Your Graph

You might notice that the y-axis is busy with grid lines. Open the AXES popover, then Lines in the toolbar to clean this up. Select the first and second y-axes and turn grid lines 'off.'

Grid Lines

Next, ensure that all your y-axes range starts at 0. Open the Axes popover, then Range and adjust it to 0. Do this for all y-axes.

Range

Your graph should now look something like this:

Progress2

Within the legend on the right side of the graph, you can label your 'Col2' trace 'Cost,' Col3 'Output' and Col4 'Defective.'

Legend

Your plot should now look something like this. In order to get the graph at the top of the tutorial, you’ll need to style it a little more. You can adjust the 'Lines/Markers' within the TRACES popover.

Lines/Markers

We’ve titled our chart. We've also colored-coded our y-axis labels to our traces. You can even add 'Tick Prefixes' within the AXES popover and 'Labels' tab. If you feel so moved, you can even color-code the 'ticks' to your traces. Finally, we’ve linked to our source data in the x-axis label area.

Color Coded

You can download your finished Plotly graph to embed in your Excel workbook. We also recommend including the Plotly link to the graph inside your Excel workbook for easy access to the interactive Plotly version. Get the link to your graph by clicking the 'Share' button. Download an image of your Plotly graph by clicking EXPORT on the toolbar.

Final

To add the Excel file to your workbook, click where you want to insert the picture inside Excel. On the INSERT tab inside Excel, in the ILLUSTRATIONS group, click PICTURE. Locate the Plotly graph image that you downloaded and then double-click it. Notice that we also copy-pasted the Plotly graph link in a cell for easy access to the interactive Plotly version.

Excel

Still need help?
Contact Us

For guaranteed 24 hour response turnarounds, upgrade to our Premium or Enterprise plans.