Skip to main content

Please don't use pie charts

I don't like pie charts. I don't like them because they fail to convey information. They do that because people have a really hard time judging relative areas instead of lengths. Wikipedia mentions some of the reasons why pie charts are generally poor.

I'd go a little further and say that pie charts are really only useful when a small number of categories of data are far, far greater than others. Like this image from Wikipedia of the English-speaking peoples:



Yep, there are lots of Americans.

Once you get data that isn't widely different or you have lots of categories your pie chart would be better as either a bar chart, or as simply a data table. Here's a particularly bad pie chart from a blog about Microsoft Office. It depicts the number of features added in various releases.



Literally eveything is wrong with this pie chart. The data being presented is the number of features added per release. Releases occur chronologically. So an obvious choice would be a bar chart or a line chart for cumulative information with time going from left to right. Instead we have to follow the chart around clockwise (finding the right starting point) to follow time.

And since the releases didn't come out at equal intervals it would be really nice to compare the number of features added with the amount of time between releases.

The pie chart has no values on it at all. We don't get the actual number of features, or just the percentage added. So we are left staring at the chart trying to guess the relative sizes of the slices. And that's made extra hard by the chart being in 3D. For example, how do Word 2000 and Word 2003 compare?

But if you still must use pie charts, I beg you not to use 3D pie charts. Please, they are simply an abomination. Making them 3D just makes them even harder to interpret.

Comments

Alan said…
I felt exactly the same way when I saw that Word pie chart. Horrible.
Brent Miller said…
You speak the truth.

Read Edward Tufte's pie chart thread for more gospel.
garlicandchile said…
Lol, wow. I saw this 'Word' piechart on a link from HackerNews, and i was thinking the same exact thing, what a horrible, horrible pie chart.
BenMc said…
I'll slightly disagree.

A pie chart with just 2 or 3 categories is VERY effective.

Do more people have cats or dogs?

If the piece of pie has a bigger section for dogs, then it's done it's job quite well.

However, if there are a 5 or more oddly shaped wedges, I agree completely.
Unknown said…
I saw that pie chart this morning too (on Ars Technica, if I'm not mistaken). First word that sprang to mind was 'rubbish'. Pie charts are rarely used effectively.
Playing devil's advocate here a bit, (because I hate the Word pie chart too), but using a time-based x-axis for that is only interesting if you're showing differences over time. They weren't, they were showing the differences over releases. They are chronological but that's not the point here. I think perhaps a stacked bar would have been a better way to go though.
dasil003 said…
Pie charts are indeed hard to read. However if you leverage past pie-eating experience you can improve your interpretation. Just imagine the pie chart is actually made of your favorite pie and you are being served the various pieces. How do you feel about the different sized pieces? Your experience will be much more nuanced than a bar chart ever could achieve.
Marius Gedminas said…
You forgot to mention the ingenious re-use of colours.
quaid said…
This is a great post with a highly interactive tool that demonstrates all about the problems of information display:

http://understandinguncertainty.org/node/233

It takes the "Pie charts are bad, mmmkay?" to the next level.
martijn said…
@BenMc
A pie chart with just 2 or 3 categories is VERY effective.

Do more people have cats or dogs?

If the piece of pie has a bigger section for dogs, then it's done it's job quite well.


I disagree. If you want to compare quantities then pie charts are hardly ever a good idea; even with 2 or 3 categories a block chart would give a much clearer answer to the question which pet do more people have.

Pie charts are useful exactly when small differences don't really matter, like in the English-speaking peoples example: what matters here is that the US has by far the most English speakers, with the UK a clear second and Australia and Canada "more or less equal third". If it did matter that Canada has about 25% more English speakers than Australia a block chart should have been used.
Anonymous said…
your examples don't do your argument justice. I see what you are getting at, but the info that the graphs are trying to convey is done with the pie graphs. Sure a different kind of graph could have been used, but any person with an IQ above 50 will understand the pie chart. The visualization of the pie segments easily portrays the number of features introduced in each version of word (which the graph is portraying -- and honestly, you don't need concrete numbers -- the general idea is there) If you want the nit-picky details, read the freaking user manual.
Steve Fenton said…
@dasil003 - you could make a column chart with frankfurters if you want that kind of reaction!
Unknown said…
Some people use pie chart in a very ineffective way. That's all. Pie chart is as good (& bad) as any other chart--you just need to choose the right one to show what you want to show the most.
Ben Garvey said…
Only good use of a pie chart
http://yfrog.com/kiz0xuzsj
Ben Garvey said…
Only good use of a pie chart
http://yfrog.com/kiz0xuzsj
avanderveen said…
Also, Pie charts a a pain in the ass if you're colour blind.
Anonymous said…
Pie charts do have some advantages but not many

Popular posts from this blog

Your last name contains invalid characters

My last name is "Graham-Cumming". But here's a typical form response when I enter it:


Does the web site have any idea how rude it is to claim that my last name contains invalid characters? Clearly not. What they actually meant is: our web site will not accept that hyphen in your last name. But do they say that? No, of course not. They decide to shove in my face the claim that there's something wrong with my name.

There's nothing wrong with my name, just as there's nothing wrong with someone whose first name is Jean-Marie, or someone whose last name is O'Reilly.

What is wrong is that way this is being handled. If the system can't cope with non-letters and spaces it needs to say that. How about the following error message:

Our system is unable to process last names that contain non-letters, please replace them with spaces.

Don't blame me for having a last name that your system doesn't like, whose fault is that? Saying "Your last name …

All the symmetrical watch faces (and code to generate them)

If you ever look at pictures of clocks and watches in advertising they are set to roughly 10:10 which is meant to be the most attractive (smiling!) position for the hands. They are actually set to 10:09.14 if the hands are truly symmetrical. CC BY 2.0image by Shinji
I wanted to know what all the possible symmetrical watch faces are and so I wrote some code using Processing. Here's the output (there's one watch face missing, 00:00 or 12:00, because it's very boring):



The key to writing this is to figure out the relationship between the hour and minute hands when the watch face is symmetrical. In an hour the minute hand moves through 360° and the hour hand moves through 30° (12 hours are shown on the watch face and 360/12 = 30).
The core loop inside the program is this:   for (int h = 0; h <= 12; h++) {
    float m = (360-30*float(h))*2/13;
    int s = round(60*(m-floor(m)));
    int col = h%6;
    int row = floor(h/6);
    draw_clock((r+f)*(2*col+1), (r+f)*(row*2+1), r, h, floor(m…

Importing an existing SSL key/certificate pair into a Java keystore

I'm writing this blog post in case anyone else has to Google that. In Java 6 keytool has been improved so that it now becomes possible to import an existing key and certificate (say one you generated outside of the Java world) into a keystore.

You need: Java 6 and openssl.

1. Suppose you have a certificate and key in PEM format. The key is named host.key and the certificate host.crt.

2. The first step is to convert them into a single PKCS12 file using the command: openssl pkcs12 -export -in host.crt -inkey host.key > host.p12. You will be asked for various passwords (the password to access the key (if set) and then the password for the PKCS12 file being created).

3. Then import the PKCS12 file into a keystore using the command: keytool -importkeystore -srckeystore host.p12 -destkeystore host.jks -srcstoretype pkcs12. You now have a keystore named host.jks containing the certificate/key you need.

For the sake of completeness here's the output of a full session I performe…