Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.charting
David Benson
 
Posts: n/a
Default Pie Chart Data Labels

I recently discovered a curious "feature" of Excel. If you create a pie
chart, and label the slices of the pie with data labels that include the
percentage, Excel sometimes adjusts the values in unexpected ways.

As far as I can tell, this only happens when the percentages are formatted
as whole-number percents (e.g., "57%"). In this situation, Excel will
adjust values so that the sum of all of the percentages around the pie is
exactly 100%.

I discovered this situation when I created a pie chart that had 7 slices.
The percentage associated with one of the slices appeared in the data as
"0.572702...". However, Excel displayed the value in the pie chart as
"56%". It did not seem to matter if I generated the pie from actual data,
or if I manually converted the data into percentages. As it happened,
several of the other values had been rounded up, so Excel took it upon
itself to change this value to compensate and make the percentages add to
exactly 100%.

Here are the percentages for each of the slices in the pie. The first
column of percentages is what's displayed if I format for 4 digits; the
second column is the display if I reduce to 1 decimal digit; and the third
column is the display if I show only whole-number percents:

1 - 2.0687% 2.1% 2%
2 - 3.7651% 3.8% 4%
3 - 0.7778% 0.8% 1%
4 - 3.0802% 3.1% 3%
5 - 18.5323% 18.5% 19%
6 - 57.2702% 57.3% 56% <===
7 - 14.5058% 14.5% 15%

Total 100.1% 100%

As you can see, when I format the data labels to display a decimal digit,
then Excel correctly rounds the displayed value for Slice 6 to "57.3%".
With this format, the sum of the percentages around the pie did not add up
to exactly 100% -- the sum of displayed alues was 100.1% in this case. If I
formatted the data lables to display no decimal digits, but forced the
display to contain a decimal point, then Excel rounded the value for Slice 6
to "57.%". The unauthorized adjustment occurred only when I formatted for
whole-number percents.

Has anyone else out there observed this kind of behavior?


-- David Benson



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I print comments on a chart? Tom Z. Charts and Charting in Excel 11 March 16th 06 08:44 PM
Can I use data from different worksheets to create a chart Dona Charts and Charting in Excel 2 March 14th 06 01:47 AM
How to add data labels from a series not displayed on a chart doctor bm Charts and Charting in Excel 2 March 1st 06 12:41 AM
Excel Macro to Copy & Paste [email protected] Excel Worksheet Functions 0 December 1st 05 01:56 PM
How do I get my data labels on a pivot chart to retain their form. s de maia Charts and Charting in Excel 1 March 18th 05 03:34 AM


All times are GMT +1. The time now is 04:50 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"