Telling Stories with Data: The Slopegraph

One of the original purposes of this blog was to explore how data visualization techniques could contribute to development, on both the academic and practical side. Today I thought I’d get back to that by presenting to you the Slopegraph. Read on to find out some of the challenges I faced in creating it and whether it’s right for your data.

What is a Slopegraph?

The slopegraph was invented by data visualization hero Edward Tufte back in 1983. Unlike Tufte’s other innovations, such as the sparkline, this one didn’t really catch on — in fact, Tufte didn’t even give it a name until 2002. Last week blogger Charlie Park was able to find only three examples on the entire Internet, most of which varied from the original concept in some way (such as comparing different types of data).

As Park explains, the slopegraph or table-graphic is basically a ‘super-close zoom in on a line chart.’ Why would this be useful? In classic Tuftian fashion, the slopegraph weeds out the junk to focus on specific aspects of the information being presented: the hierarchy or rank order at each period; the rate of change over each period; how the rates of change compare to each other; and any notable deviations from the trend (e.g. China above). Done correctly, the slopegraph has zero ‘non-data ink.’

Why Make One?

For me, it was mainly for the challenge, and to see what a slopegraph could do that a more traditional line chart couldn’t. It was an interesting experience: since there are no automated tools, making a slopegraph is hard work and requires careful planning and attention to detail. I spent an entire working day on this, and scrapped three previous versions before arriving at one I even sort of liked. This proves another point that Tufte, a notable critic of PowerPoint, has been making for years: modern data presentation tools often obfuscate as much as they reveal. As long as Excel has that big colorful pie chart button, people will continue filling their papers with worthless pie charts. And until there is a slopegraph tool available, I doubt most people will be making slopegraphs.

Still, while I can’t see the slopegraph becoming a hot new trend, I think they could be very effective in certain applications where both rank order and relative rate of change are important. I also like that they force you to really think about the story that you’re trying to tell with your data, rather than just slapping together a table or line chart because you have a bunch of numbers and you can. While some advocacy groups and media organizations (like Good magazine) have done some amazing things with visualizing development-related data, the quality of visual data presentation by development researchers is still generally abhorrent. If you are lucky enough to be paid to sit in a university office and think about things, you could find a worse way to spend a day than making a graph like this, especially if the experience encourages you to think more carefully in the future about what you are trying to say with your data.

What I Liked

As I said, the slopegraph makes you think hard about the story you are trying to tell. In this case, the basic story is one that anyone involved with development has already heard a million times: while some poor countries have ‘taken off,’ most remain poor. Another interesting aspect of this particular data set and choice of time periods is the lack of a consistent pattern in terms of region, culture, or type of government determining which country ‘takes off’ and which one stagnates: the three most successful countries, China, Morocco, and India, have very little in common except that they all started poor and became rich. Prior versions of the chart using slightly different time periods and GDP measures produced a list where Botswana and Equatorial Guinea were the big breakouts; another version starting in 1970 had Vietnam. Recognizing that my choices would reflect the story told by this chart was an important part of the process for me.

However, what I really like about this style of presentation is that it breaks the story down into discrete sub-narratives by country and decade. As I alluded to yesterday, I am somewhat skeptical of tendency in development economics to focus on large-scale trends — with the implication often being that this will allow us to devise ‘universal’ rules. Too often economists write off the outliers as uninteresting, unimportant, or even harmful to their analysis. But given the rarity of the outcome development economists are searching for — poor country becomes rich country — it seems like the outliers are exactly what they should be focusing on. Looking at this chart, the natural question for the uninitiated would be “What’s the deal with China?” not “Hey, what’s up with Burkina Faso, Ethiopia, and Malawi?”

This chart also helps to generate questions that would not be so obvious in a more granular presentation, especially to those not accustomed to reading charts, as the human brain is pretty good at recognizing and comparing the slopes of straight lines. Looking at the chart for a few minutes quickly reveals the important moments in the economic histories of these diverse countries: what happened in Uganda in the 70s? China in the 80s? Most countries in the 2000s? And what the hell is wrong with Zimbabwe? You can also discern other interesting pieces of data, such as the fact that economic dynamo India actually only surpassed economic basketcase Pakistan in per-capita GDP relatively recently. Some countries have been particularly volatile, like Malawi, while Morocco was a good, steady performer. You really lose surprisingly little meaning compared to the conventional line chart, especially considering the number of distractions which are eliminated.

What Needs Work

That said, the chart did not come out as ‘clean’ as I had hoped. The colors, for example, were a last-minute addition. I had hoped to get by with shades of gray, but that clearly wasn’t going to work for this data set. Getting the lines and especially the scale right was also painstaking and laborious, and still didn’t yield fully satisfying results, as I had to stick China in like an afterthought — for proper scale China would need to be almost a full chart length higher. That was particularly unsatisfying because the rise of China is one of the main takeaways of the chart. Thankfully, I settled on an initial country set that didn’t include Equatorial Guinea, which now has a PPP per-capita GDP of $31,000! This shows that it’s important to distinguish ‘interesting’ outliers from the ones that really are just aberrations (Equatorial Guinea has less than 700,000 people and discovered one of Sub-Saharan Africa’s largest reserves of oil in 1996).

I think that in addition to the lack of good automated tools, the use of slopegraphs will be mainly limited by the fact that it’s really only suited for certain types of data. To make full use of the slopegraph you need a dataset which is not too ‘extreme’ and also does not have too much overlap. This data was sub-optimal in both respects: many of the poor countries are clumped up in a confusing tangle at the bottom, while the successful countries shoot right off the top of the chart. I suspect a lot of the interesting data in development particularly contains these sorts of extremes.

This chart might have been better off with only two periods, 1960 and Today. This would certainly simplify the overall message, but would remove some of the interesting nuances. I even think the current version has a bit of ‘narrative tension’ as you follow each line across to see what happened to that country — particularly the countries which are grouped together at the beginning (the grouping also begs some important questions: why India and not Uganda? Why China, not Ethiopia?).

Future Prospects?

The extreme simplicity of the slopegraph gives the creator lots of room to add additional information without overloading the reader. For example, you could vary the color of the lines based on some third piece of information, like whether or not the country had experienced a civil war or structural adjustment program during that period. The slopegraph could help to make correlations much more intuitive to readers who are not accustomed to interpreting statistical data (untrained readers have a lot of problems interpreting scatter plots, for example). Slopegraphs are also great when the rank order is really important. For per-capita GDP, I don’t think most development economists care as much about the relative ranks of countries as they do why some countries grow and others don’t. But for data like the ranks of export goods*, and probably lots of other kinds of ‘power law’ data, such as city sizes, this could be a useful presentation option. Hopefully some tools will be developed to make creating them easier for non-Illustrator experts.

* I might actually try improving on the slopegraph-style charts used in this paper the next time I have a free day. Stay tuned!

Advertisement

One thought on “Telling Stories with Data: The Slopegraph

  1. Pingback: Telling Stories with Data II: The Slopegraph Strikes Back | In Event of Moon Disaster

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s