Category: Methodology

Cardboard and scissors to make Sankey diagrams

The website of Nottingham City Schools offers a variety of materials that can be used by teachers in their courses. One of the key areas in the science field is ‘energy’.

The site has a demonstration of how Sankey diagrams may be used to represent transfer of energy, including a PowerPoint and “stories”, for which pupils can create a Sankey diagram by using tokens cut from cardboard.

I think this is a great idea, as it supports the understanding of the energy topic with a haptic and, very importantly, a visual approach.

Using Sankey diagrams for visualizing web site performance

UK-based Stuart Brown at Modern Life in his latest post (“The Varying Virtues of Site Performance Metrics”) uses a Sankey diagram to visualize web site performance. This is a rather novel idea of using Sankey diagrams, but hey, why not?

This nicely done Sankey diagram – in this case without any absolute or relative numbers – shows where web site visitors come from (input flows from the left side), and if their visit can be considered successful (that is, meeting the “goal” of the site operator) or not as output flows to the right side. Returning visitors are shown with a “browsing loop” in the Sankey diagram.

I really like this Sankey diagram and I would love to see web site metrics being visualized in this way. It really is a good visualization and can show how a website performs, although Brown acknowledges that “there simply isn’t any single great method of gauging a site’s performance”.

Coming back to the Sankey diagram itself, it does however have a small flaw. Look at the grey arrows for “Bounce” and “Non-goal visit”. The latter does not connect to the “Page Load” node, but rather seems to dive under the “Bounce” flow and appears where this one branches of vertically.

I have created two alternative Sankey diagrams where these two flows set off from the “Page Load” box parallel (stacked), rather than in an overlay manner. The overall quantity represented by the flows on the output side should be equal to the number of visitors on the input side. The first diagram keeps the original idea of the browsing loop coming in from the top, the second one hooks it on the left side of the box.


Alternative version:

As for the colors of the two diagrams above, sorry Stuart, didn’t hit the right values right away…

Sankey Diagrams in Material Flow Accounting

Another field where Sankey diagrams are used widely is Material Flow Accounting, the analysis of material flows on a national or regional level. MFA focuses on bulk materials or individual substances (e.g. zinc, copper, cadmium) and the quantities in which they enter, leave or accumulate in a national economy.

The diagram below is from a peer-reviewed paper presented at the 4th LCA conference in Australia (van Beers, van Berkel, Graedel: The Application of Material Flow Analysis for the Evaluation of the Recovery Potential of Secondary Metals in Australia, 2005). It shows the copper flows within the system boundary of Australia, the unit is Gg/year (= 1000 metric tons per year).

This “clustered” Sankey has six different flow widths, grouping together flow quantities within a specific range (e.g. <10, 10 < 30,9, …). Flows larger than 999 Gg/year are not shown any wider. This avoids that very large quantities “spoil” the whole diagram, as smaller flows become less significant in Sankey diagrams to scale.

An alternative way to overcome the problem or very wide flows in a Sankey diagram spoiling the chart would be to define a cut-off quantity. Flows that are large than the cut-off quantity are excluded from the scale, and are shown with a hatch or moirĂ©e pattern. The two Sankey diagrams below were made based on the data from the above publication. The first one shows the large “Ore” flow with a cut-off level at 300 Gg/year (an additional note warns the reader that this flow is not to scale”, while the second diagram is fully to scale.


Very thin arrows additionally get explicit arrow heads to be able to identify their flow direction.

Feel free to comment

Sankey – the movie. Or: moving Sankey diagrams

Mark Barrett, director of a UK-based energy consultancy Senco, has developed several energy models.

The SEEScen model (Society, Energy and Environment Scenario model)…

…incorporates 11 energy end uses (motive power, lighting, heating etc.) across 15 sectors. Some of these end uses have physical models; for example, domestic space heating and cooling are estimated with a model of a house which allows the effects of parameters such as insulation and internal temperatures to be examined.

Sankey diagrams for several years have been put together to make a short “film” how energy requirements may change over the years, and what shifts might be expected between different ways of energy generation.

To view this animation click on the image (there are some seconds between the frames, be patient).

To be able to see the details, download the Flash move or the GIF from the SEEScen webpage. Make sure you watch the film in the original size.The website www.senco.co.uk has gone offline (?), go to Mark Barrett’s page instead.

This is a neat idea, and it gives a whole new dimension to Sankey diagrams! On a side note: as far as I am informed, there are only two software tools capable of handling timelines in Sankey diagrams, S.DRAW and SankeyVis.…

A nice one from Poland

On my quest for more interesting Sankey diagrams I stumbled across a wykres Sankeya on a web page from Poland, which I reproduced here using ifu’s e!Sankey tool.

It shows the advantage of energy cogeneration plants over energy production in separate plants. From a base value of 100 a yield of 85% can be reached in cogeneration plants (35% electric energy, 50% heat energy – the original text accompanying the diagram says 30% electric energy, 55% heat energy) with 15% losses. To get the same energy amount from separate energy generation plants, the required energy feedstock is 1.48 times higher, with losses more than four times higher (63:15), especially originating from the generation of electricity.

While I am far from fostering one or the other technology with this post, I think this Sankey diagram merits special attention, because it is actually a 2-in-1 diagram (both with flow direction left-to-middle and right-to middle) and a baseline scenario comparison. A very nice idea!

Java applet to explore Sankey energy diagram interactively

Researchers of the “energy flow” project at Weimar’s Bauhaus University have developed a Java applet to explore a Sankey energy diagram interactively.


The accompanying explanation says:

We present a system that allows users to interactively explore complex flow scenarios represented as Sankey diagrams. Our system provides an overview of the flow graph and allows users to zoom in and explore details on demand. The support for quantitative flow tracing across the flow graph as well as representations at different levels of detail facilitate the understanding of complex flow situations.

The energy flow in a city serves as a sample scenario for our system. Different forms of energy are distributed within the city and they are transformed into heat, electricity, or other forms of energy. These processes are visualized and interactively explored. In addition our system can be used as a planning tool for the exploration of future scenarios by interactively manipulating different parameters in the energy flow network.

The Java-based online version (in German) allows the visitor to interactively explore the Sankey diagram. They can zoom in, move the nodes, or call additional data for individual layers.