您可能以前看过桑基(Sankey)图。桑基(Sankey)图(也称为桑基(Sankey)图)对于显示流程特别有用,可帮助人们可视化系统内的大额转移。例如,桑基(Sankey)图可能会显示资金、时间或能源等资源如何在整个过程中移动。桑基(Sankey)图也可以很好地显示决策树。
如果您想在视觉上突出显示一个复杂的过程,请考虑制作一个桑基(Sankey)图。有几个网站可以创建桑基(Sankey)图。虽然有些依赖于具有一定编程知识的用户,但其他人都可以访问。我们将看看其中的几个。
什么是桑基图?
桑基图以Matthew Henry Phineas Riall Sankey的名字命名,他是爱尔兰工程师和皇家(Royal) 工程师(Engineers)队的船长,他制作了一张显示蒸汽机能源效率的图表。
要创建桑基(Sankey)图,您可以学习如何(learn how to code)自己编写代码或使用网络应用程序生成一个。
创建桑基图的网站
虽然一些编码知识可能会有所帮助,但即使您不了解Python或编程语言 R,您仍然可以创建桑基(Sankey)图。下面的一些网站为具有一定编程经验的人提供了选项。大多数根本不需要任何编程知识。
要使用SankeyMATIC,您需要添加输入、自定义图表的外观,然后将其导出为PNG图像或矢量代码 ( SVG )。输入格式简单易懂。如果您想将图表导入Adobe Illustrator等程序以进行额外修改,则矢量代码选项非常有用。
2.桑基图生成器(The Sankey Diagram Generator)
Acquire的Sankey Diagram Generator是一个网络应用程序,可让您以三种格式之一上传数据:
您可以调整每个流的颜色和大小以及显示的数字的小数位和流的透明度。当您选择保存(Save)按钮时,该站点将生成您可以复制和粘贴的代码。您还可以下载图像或通过电子邮件分享。
Visual Paradigm的Sankey Diagram Maker功能丰富。从他们漂亮的模板之一开始(Start),然后添加您的特定数据以进行编辑。
您可以更改字体样式和颜色或添加照片和图标,以使您的桑基(Sankey)图脱颖而出。该网站不是免费的,但您可以注册免费试用 30 天。之后,每位用户每月的费用将在 4-15 美元之间。
4.显示器(Displayr)
Displayr提供了一个免费的工具来制作桑基图。不过,您需要注册一个帐户。完成后,您将可以访问功能强大的用户界面,您可以在其中从计算机或云端上传数据集。从那里,您可以使用自动布局或手动调整它。
Displayr不仅适用于桑基(Sankey)图,您还可以访问各种不同的数据可视化,如热图、直方图(histograms)和饼图(pie charts)。然而,公平(Fair)的警告,您需要一个付费帐户才能下载您创建的桑基(Sankey)图。
5.图表指南(Chartguide)
Chartguide不是一个可以创建Sankey图表的网站。相反,他们将教您如何使用Excel和Power User附加组件创建桑基(Sankey)图。如果您的数据已经在电子表格中,那么值得尝试这种方法来自己生成桑基(Sankey)图,而无需离开Excel。
6. Dénes Csala 的桑基图生成器(Dénes Csala’s Sankey Diagram Generator)
这个Sankey Diagram Generator在线工具既时尚又简单。创作者(Creator) Dénes Csala说:“它支持自循环,在水平和垂直方向上围绕节点移动以及加载和保存图表!” 用户还可以更改节点的不透明度和颜色。
很明显,这个开源项目(open-source project)是对其创建者的热爱。你也可以在 GitHub 上找到它(find it on GitHub)。
7.高图(Highcharts)
如果您想编辑自己的代码,Highcharts是创建桑基(Sankey)图的绝佳选择。除了能够将您的数据输入到简单的配置预览(Configuration Preview)中,它们还提供了直接在JSFiddle或Codepen中编辑代码的按钮。
与Visual Paradigm中的工具类似,Highcharts可让您访问各种图表类型,如仪表、热图和树图,以及散点图和气泡图。
8. R图库(R Graph Gallery)
R Graph Gallery是一个可以找到近 400 个图表的地方,所有图表都带有可重现的代码。R 是一个主要用于统计计算的软件环境,非常适合创建桑基(Sankey)图。它使用 networkD3,这是一个构建交互式图表 的HTML小部件。(HTML)
在R Graph Gallery(R Graph Gallery)中找到您喜欢的Sankey图表,然后选择Show code链接以根据需要对其进行自定义。我们查看的代码注释良好且易于理解。
9. Python图形库(Python Graph Gallery)
如果 R 不是你的果酱,但Python是,那么请查看Python Graph Gallery以获取可重现和可定制的Sankey图表。这些图表使用Python的(Python)Plotly库,该库具有专门用于创建Sankey图的功能。您还可以使用具有自己的Sankey函数的 matplotlib 库查找示例。在这两种情况下,如果您喜欢Python,这是一个很好的资源。
10.谷歌图表(Google Charts)
在我们的网站列表中,您可以创建Sankey图表的最后一个条目来自Google Charts。它提供了一个简单的桑基(Sankey)图以及一个具有多个级别的示例和代码。对于每一个,您都可以控制颜色、自定义标签和调整节点。每个方面都有详细记录,因此您可以成为配置选项和格式化数据的最佳方式方面的专家。
与上面的一些条目非常相似,Google Charts为各种类型的数据可视化提供了示例和代码,因此如果Sankey图表无法按照您想要的方式讲述您的故事,您可以轻松尝试其他方式来可视化您的数据。
10 Best Websites to Create a Sankey Chart
You’ve probably seen a Sankey chart before. Sankey charts (also called Sankey diagrams) are espeсially uѕeful to show a flow, helping peoplе visualize bіg transfers within a system. For example, a Sankey chart might show how a resourcе likе money, time, or energy moves throughout a process. Sankey diagrams are аlso good to show deсiѕion trees.
If you want to visually highlight a complex process, consider making a Sankey chart. There are several websites where you can create a Sankey chart. While some rely on users having some programming knowledge, others are accessible to everyone. We’ll look at a few of each.
What Is a Sankey chart?
Sankey charts are named for Matthew Henry Phineas Riall Sankey, an Irish engineer and captain in the Royal Engineers who made a diagram showing the energy efficiency of a steam engine.
To create a Sankey chart you can either learn how to code one yourself or use a web app to generate one.
Websites to Create a Sankey Chart
While some coding knowledge can be helpful, even if you don’t know Python or the programming language R, you can still create a Sankey chart. Some of the websites below have options for people with some programming experience. Most don’t require any programming knowledge at all.
To use SankeyMATIC, you add your inputs, customize your chart’s appearance, and then export it as a PNG image or as vector code (SVG). The input format is simple and easy to understand. The vector code option is nice if you want to import your chart into a program like Adobe Illustrator for additional modification.
The Sankey Diagram Generator from Acquire is a web app that lets you upload your data in one of three formats:
You can adjust the color and size of each flow as well as the decimal places of numbers displayed and the transparency of the flows. When you select the Save button, the site will generate code you can copy and paste. You can also download the image or share it via email.
The Sankey Diagram Maker from Visual Paradigm is packed with features. Start with one of their beautiful templates and add your specific data to edit it.
You can change font styles and colors or add photos and icons to make your Sankey chart stand out. This site isn’t free, but you can sign up for a free 30-day trial. After that, it’ll cost you between $4-15 per user, per month.
Displayr offers a free tool to make Sankey charts. You’ll need to sign up for an account, though. Once you do, you’ll get access to a powerful user interface where you can upload a data set from your computer or from the cloud. From there, you can use an automated layout or tweak it manually.
Displayr isn’t just for Sankey diagrams—you’ll also have access to all kinds of different data visualizations like heatmaps, histograms, and pie charts. Fair warning however, you’ll need a paid account to download the Sankey chart you created.
Chartguide isn’t a website where you can create a Sankey chart. Instead, they’ll teach you how to create a Sankey chart using Excel with the Power User add-on. If your data is already in a spreadsheet, it’s worth trying this method to generate Sankey charts yourself without ever leaving Excel.
This Sankey Diagram Generator online tool is sleek and simple. Creator Dénes Csala says, “It supports self loops, moving around nodes in both horizontal and vertical directions and loading and saving diagrams!” Users also have the ability to change the opacity and color of the nodes.
It’s clear that this open-source project is a labor of love for its creator. You can also find it on GitHub.
If you want to edit your own code, Highcharts is a great option for creating a Sankey chart. In addition to the ability to enter your data into the simple Configuration Preview, they also offer buttons to edit the code directly in JSFiddle or Codepen.
Similar to the tool from Visual Paradigm, Highcharts gives you access to a wide variety of chart types like gauges, heat and tree maps, and scatter and bubble charts.
The R Graph Gallery is a place where you can find nearly 400 charts, all with reproducible code. R is a software environment mostly used for statistical computing, which makes it perfect for creating Sankey charts. It uses networkD3, which is an HTML widget that builds interactive charts.
Find a Sankey chart you like in the R Graph Gallery and then select the Show code link to customize it however you want. The code we looked at was well-commented and easy to follow.
If R isn’t your jam but Python is, then check out the Python Graph Gallery for reproducible and customizable Sankey charts. These charts use the Plotly library for Python which has a function specifically for creating Sankey diagrams. You can also find examples using the matplotlib library which has its own Sankey function. In both cases, if you’re into Python, this is a great resource.
The last entry in our list of websites where you can create a Sankey chart comes from Google Charts. It provides an example of and code for a simple Sankey chart as well as one with multiple levels. For each, you can control the colors, customize the labels, and adjust the nodes. Each aspect is well-documented, so you can become an expert on configuration options and the best way to format your data.
Much like some of the entries above, Google Charts offers examples and code for a variety of types of data visualization, so if a Sankey chart doesn’t tell your story the way you want, you can easily try other ways to visualize your data.