Over at the TeX – LaTeX Stack Exchange (a Q&A site for users of TeX and LaTeX) this article explains “How to draw a Sankey Diagram using TikZ”. Okay, its a bit techie, but the results look good.

The original poster wanted to know how to draw a Sankey diagram using the TikZ package (TikZ is a “higher-level drawing language built on top of the PGF graphics framework”).

User Paul Gaborit came up with this example using TikZ and building his own sankeydiagram environment

The interesting thing is that flows can fork and join, and that there is a check that the sum of quantities must be equal to the quantity of sankey node to fork.

This is how the the original sample Sankey diagram looks like with this solution.

Very nice result. So for those out there used to working with TeX/LaTeX out this is actually a good solution.

Don’t miss to read the comments too (there’s one pointing to an alternative (Matplotlib and Sankey module).

Comments are closed.