Posts filed under Graphics (271)

October 18, 2014

When barcharts shouldn’t start at zero

Barcharts should almost always start at zero. Almost always.

Randal Olson has a very popular post on predictors of divorce, based on research by two economists at Emory University. The post has a lot of barcharts like this one

marriage-stability-wedding-expenses

The estimates in the research report are hazard ratios for dissolution of marriage. A hazard ratio of zero means a factor appears completely protective — it’s not a natural reference point. The natural reference point for hazard ratios is 1: no difference between two groups, so that would be a more natural place to put the axis than at zero.

A bar chart is also not good for showing uncertainty. The green bar has no uncertainty, because the others are defined as comparisons to it, but the other bars do. The more usual way to show estimates like these from regression models is with a forest plot:

marriage

The area of each coloured box is proportional to the number of people in that group in the sample, and the line is a 95% confidence interval.  The horizontal scale is logarithmic, so that 0.5 and 2 are the same distance from 1 — otherwise the shape of the graph would depend on which box was taken as the comparison group.

Two more minor notes: first, the hazard ratio measures the relative rate of divorces over time, not the relative probability of divorce, so a hazard ratio of 1.46 doesn’t actually mean 1.46 times more likely to get divorced. Second, the category of people with total wedding expenses over $20,000 was only 11% of the sample — the sample is differently non-representative than the samples that lead to bogus estimates of $30,000 as the average cost of a wedding.

October 13, 2014

Herald data blog starts

The Herald’s Data Editor, Harkanwal Singh,  announces the online site’s new ‘Data Blog’, with the first new post being a map of NZ internet affordability created by Jonathan Brewer.

This has got to be a Good Thing for data literacy in the local media.

October 8, 2014

What are CEOs paid; what should they be paid?

From Harvard Business Review, reporting on recent research

Using data from the International Social Survey Programme (ISSP) from December 2012, in which respondents were asked to both “estimate how much a chairman of a national company (CEO), a cabinet minister in a national government, and an unskilled factory worker actually earn” and how much each person should earn, the researchers calculated the median ratios for the full sample and for 40 countries separately.

The graph:

actualestimated

 

The radial graph exaggerates the differences, but they are already huge. Respondents dramatically underestimated what CEOs are actually paid, and still thought it was too much.  Here’s a barchart of the blue and grey data (the red data seems to only be available in the graph). Ordering by ideal pay ratio (rather than alphabetically) helps with the nearly-invisible blue bars: it’s interesting that Australia has the highest ideal ratio.

ceo

The findings are a contrast to foreign aid budgets, where the desired level of expenditure is less than the estimated level, but more than the actual level.  On the other hand, it’s less clear exactly what the implications are in the CEO case.

 

October 7, 2014

Marriage equality maps

The US Supreme Court declined to review seven same-sex marriage decisions today. The StatsChat-relevant aspect is the flurry of maps this prompted:

I think the New York Times (via Twitter) is my favorite version: the square statebins use geography just as an index to make states easier to find, and (in contrast to the last statebins I linked to) they’ve moved Alaska to the right place

BzS1Q2zIQAAxW3Q

 

(more…)

October 6, 2014

NZ voting cartograms

One of the problems with electoral maps is the ‘one cow, one vote’ effect: rural electorates are physically bigger, and so take up more of the map. When you combine that with the winner-take-all impact of simple colour schemes, it can look as though National won basically everything instead of just missing out on a majority.

Using a design by Chris McDowall that I linked earlier this year, David Friggens has mapped out the party votes across the country with equal area given to each electorate.  These maps show where the votes for each major party came from

big4

 

He also has maps for the minor parties, some of which have very localised support.

October 1, 2014

Climate change and flooding

flooding

The Upshot blog at the New York Times had this interactive map of the flooding risk from climate change. It lets you see the number affected in each country, and also lets you vary the estimates for how much CO2 will be emitted and how sensitive ocean levels are to CO2.

It’s missing something, though: not just New Zealand, but all the Pacific Island countries. We often get maps cut off at about 167 E longitude, and we can just whinge quietly about the New York view of the world

Steinberg_New_Yorker_Cover

but in  this context, where some of these islands will cease to exist if sea levels rise as predicted, leaving them out seems more inappropriate than usual.

September 26, 2014

Small multiples and graphical details

A really great long-form post on graphics and design by Lena Groeger at the ProPublica Nerd Blog

Waldo, and the eternal search for him, can actually tell us quite a lot about design. In many ways, Waldo is a great example of what NOT to do when using wee things in your own work. So with Waldo as our anti-hero, let’s take a look at how people read and interpret small visual forms, why tiny details can be hugely useful, and what principles we can apply to make all these little images and moments work for us as designers.

 

PhD gender gap

From Scientific American and Periscopic, an interactive display of international gender differences in PhDs awarded in various fields.

phd-gap

September 18, 2014

Interactive election results map

The Herald has an interactive election-results map, which will show results for each polling place as they come in, together with demographic information about each electorate.  At the moment it’s showing the 2011 election data, and the displays are still being refined — but the Herald has started promoting it, so I figure it’s safe for me to link as well.

Mashblock is also developing an election site. At the moment they have enrolment data by age. Half the people under 35 in Auckland Central seem to be unenrolled,which is a bit scary. Presumably some of them are students enrolled at home, and some haven’t been in NZ long enough to enrol, but still.

Some non-citizens probably don’t know that they are eligible — I almost missed out last time. So, if you know someone who is a permanent resident and has lived in New Zealand for a year, you might just ask if they know about the eligibility rules. Tomorrow is the last day.

August 30, 2014

Funding vs disease burden: two graphics

You have probably seen the graphic from vox.comhyU8ohq

 

There are several things wrong with it. From a graphics point of view it doesn’t make any of the relevant comparisons easy. The diameter of the circle is proportional to the deaths or money, exaggerating the differences. And the donation data are basically wrong — the original story tries to make it clear that these are particular events, not all donations for a disease, but it’s the graph that is quoted.

For example, the graph lists $54 million for heart disease, based on the ‘Jump Rope for Heart’ fundraiser. According to Forbes magazine’s list of top charities, the American Heart Association actually received $511 million in private donations in the year to June 2012, almost ten times as much.  Almost as much again came in grants for heart disease research from the National Institutes of Health.

There’s another graph I’ve seen on Twitter, which shows what could have been done to make the comparisons clearer:

BwNxOzdCIAAyIZS

 

It’s limited, because it only shows government funding, not private charity, but it shows the relationship between funding and the aggregate loss of health and life for a wide range of diseases.

There are a few outliers, and some of them are for interesting reasons. Tuberculosis is not currently a major health problem in the US, but it is in other countries, and there’s a real risk that it could spread to the US.  AIDS is highly funded partly because of successful lobbying, partly because it — like TB — is a foreign-aid issue, and partly because it has been scientifically rewarding and interesting. COPD and lung cancer are going to become much less common in the future, as the victims of the century-long smoking epidemic die off.

Depression and injuries, though?

 

Update: here’s how distorted the areas are: the purple number is about 4.2 times the blue number

four-to-one