Peltier Technical Services, Inc.
 

Excel Chart Add-Ins | Training | Custom Solutions | Charts and Tutorials | Peltier Tech Blog


Peltier Tech
Chart Add-Ins

Peltier Tech Waterfall Chart Utility
Peltier Tech Cluster-Stack Chart Utility
Peltier Tech Box and Whisker Chart Utility
Peltier Tech Marimekko Chart Utility
Peltier Tech Dot Plot Utility
Peltier Tech Cascade Chart Utility

 

Excel Dashboards

 

Books at Amazon.com

 

Column Chart on Two Axes.

Suppose you need a column chart of data that has greatly different magnitude. The table below shows three series of data in the thousands, and a fourth in percentages.

 

Market A

Market B

Market C

Share

Jan

1195

1286

1395

15%

Feb

1173

1227

1246

12%

Mar

1196

1285

1137

10%

Apr

1087

1311

1364

13%

The column chart can't show the fourth series, because its values are so much smaller than the others.

Excel doesn't offer a built-in custom Columns On Two Axes chart type, but you know how to assign a series to the secondary axis. "That's easy," you say. "I'll just put the last series onto the secondary axis." It's a little tricky, because it's hard to select something you can't see. But you can select a visible series, then use the up and down arrow keys to change the selected series, then choose Selected Data Series from the Format menu, or use the CTRL+1 shortcut. This works great in Line charts, XY Scatter charts, and any combination charts with Columns on one axis and Lines on the other. But in a column chart, this has an unintended consequence.

Note: You can use the Chart Objects dropdown control on the Chart command bar (shown above) to identify which chart element is selected, or to select one which is difficult to click on with the mouse. In addition, the Name Box (above the top left visible cell, in the left edge of the Formula Bar) shows the name of whatever object is selected.

In a column chart, the columns on a given axis are centered over each category. Hence the single column on the secondary axis has obscured the center column on the primary axis. You can get around this problem if you use dummy series in your chart.

The trick here is to include a dummy series, using zero values to be invisible, on each axis to maintain proper positioning of each visible series. For each visible primary axis series, you need a hidden secondary axis series, and for each visible secondary axis series, you need a hidden primary axis series. The table below shows how to insert columns to set up the desired chart appearance. The upper case headers denote visible (non zero) series, while lower case headers denote hidden series.

 

PRI_1

PRI_2

PRI_3

pri_4

sec_1

sec_2

sec_3

SEC_4

Jan

[data]

[data]

[data]

zero

zero

zero

zero

[data]

Feb

[data]

[data]

[data]

zero

zero

zero

zero

[data]

Mar

[data]

[data]

[data]

zero

zero

zero

zero

[data]

Apr

[data]

[data]

[data]

zero

zero

zero

zero

[data]

Modify the original data table as shown below to provide for the hidden series.

 

Market A

Market B

Market C

pri_4

sec_1

sec_2

sec_3

Share

Jan

1195

1286

1395

0

0

0

0

15%

Feb

1173

1227

1246

0

0

0

0

12%

Mar

1196

1285

1137

0

0

0

0

10%

Apr

1087

1311

1364

0

0

0

0

13%

When this data range is charted, the result is similar to our first chart, with more empty space after the three visible columns.

Now the last four series must be assigned to the secondary axis. Select one of the visible columns, and press the up arrow key until the "Share" series (the eighth series) is selected, then assign it to the secondary axis. Before doing anything else, press the down arrow key to select the seventh series, and press the F4 function key to repeat the axis switch. Two more times press the down arrow key followed by the F4 key, so that the last four series are on the secondary axis.

The unwanted legend entries are easily hidden. Select the legend, then select the text of the legend entry (two single clicks), and press Delete.

Note: make sure you select the Legend Entry (the text for the entry you want to hide) before you press Delete. If you select the Legend Key (the small square filled with the series color) and press delete, you will delete the series. Fortunately the Undo button (or the CTRL+Z shortcut) can correct this mistake.

Finally, you should include some clues to help the reader determine which axis contains values for which series. In this example, the legend is moved above the plot area, and descriptive axis titles relate to the legend entries. To make the legend more descriptive, I redrew it and only deleted three of the dummy legend entries. For the remaining one, I changed the series name to "      " (a series of spaces), and I changed the series formatting to no fill and no border. This leaves a gap between the legend entries for the Markets and the legend entry for Share.

This technique can also be used on bar charts, as in this example:

 

 

Page copy protected against web site content infringement by Copyscape

 

Peltier Tech Waterfall Chart Utility Peltier Tech Cluster-Stack Chart Utility Peltier Tech Box and Whisker Chart Utility Peltier Tech Marimekko Chart Utility Peltier Tech Dot Plot Utility Peltier Tech Cascade Chart Utility

 

Create Excel dashboards quickly with Plug-N-Play reports.


Peltier Technical Services, Inc.

Excel Chart Add-Ins | Training | Custom Solutions | Charts and Tutorials | PTS Blog

Peltier Technical Services, Inc., Copyright © 2010. All rights reserved.
You may link to this article or portions of it on your site, but copying is prohibited without permission of Peltier Technical Services.

Microsoft Most Valuable Professional

Microsoft Most Valuable Professional

My MVP Profile