如何在Tableau中构建自定义地图可视化

Sometime last year, I got fascinated with bubble charts when I saw a data visualization video, Han's Rosling's 200 Countries, 200 Years, 4 Minutes - The Joy of Stats from BBC.

去年的某个时候,当我看到一个数据可视化视频时,我迷上了气泡图,这是Han的Rosling的200个国家,200年,4分钟-来自BBC的Stats of the Stats

如何在Tableau中构建自定义地图可视化
Data Visualization used as an effective communication tool! Awesome!
数据可视化被用作有效的交流工具! 太棒了!

什么是气泡图? (What are bubble charts?)

Wikipedia*
如何在Tableau中构建自定义地图可视化
An example of Bubble Chart
气泡图示例

Last January 2019, I was checking Tableau Desktop, a data visualization software, and their basic tutorials included a heat map of the United States.

去年2019年1月,我正在检查Tableau Desktop这个数据可视化软件,其基本教程包括美国的热点地图。

如何在Tableau中构建自定义地图可视化

什么是热图? (What are heat maps?)

Wikipedia*

While going through the Tableau tutorial, I remembered the bubble charts and started looking for an inspiration. I was googling for image silhouettes and got the result below:

在浏览Tableau教程时,我想起了气泡图并开始寻找灵感。 我正在搜寻图像轮廓,并得到以下结果:

如何在Tableau中构建自定义地图可视化

This led to my short data visualization experiment. I looked for a dataset and found NBA Injuries from 2010-2018, on Kaggle . I modified the dataset to make it simple to use.

这导致了我简短的数据可视化实验。 我寻找了一个数据集,并在Kaggle上发现了2010- 2018年的 NBA伤害。 我修改了数据集以使其易于使用。

I ended up giving up on using Tableau and creating my own data visualization in Microsoft Powerpoint. Still, my friends were amazed and thought that I used a data visualization tool.

我最终放弃了使用Tableau并在Microsoft Powerpoint中创建自己的数据可视化。 不过,我的朋友还是很惊讶,并认为我使用了数据可视化工具。

如何在Tableau中构建自定义地图可视化
Created with Microsoft Powerpoint
使用Microsoft Powerpoint创建

Fast track to August 2019, I returned to studying the Tableu tutorial. Just look at the result below! =)

快速浏览到2019年8月,我回到了学习Tableu教程的地方。 请看下面的结果! =)

如何在Tableau中构建自定义地图可视化
Created with Tableau
用Tableau创建

我是怎么做的? (How did I do it? )

I used Excel, Tableu, and a little bit of creativity.

我使用了Excel,Tableu和一些创意。

Feel free to follow along and create the same dataset and visualization.

随时跟随并创建相同的数据集和可视化。

Steps

脚步

  1. Create an Excel file. Column B and Column C will serve as the location on the X-axis and Y-axis of an item in Tableau. Count represents how many players had a particular injury from 2010 to 2018.

    创建一个Excel文件。 B列和C列将用作Tableau中项目在X轴和Y轴上的位置。 计数表示从2010年到2018年有多少名球员受到了特殊伤害。
如何在Tableau中构建自定义地图可视化

2. Download Tableau Desktop here.

2. 在此处下载Tableau Desktop。

3. Open the Tableau Desktop App

3.打开Tableau Desktop应用程序

4. Click Connect To a File >  Microsoft Excel

4.单击连接到文件 > Microsoft Excel

如何在Tableau中构建自定义地图可视化

4. Drag a Sheet from the left pane to the right pane

4.将图纸从左窗格拖到右窗格

如何在Tableau中构建自定义地图可视化

5. At the bottom, click the Sheet.

5.在底部,单击图纸。

如何在Tableau中构建自定义地图可视化

6. At the menu, click Background Images > Sheet

6.在菜单上,单击背景图像 > 图纸

如何在Tableau中构建自定义地图可视化

7 . Click Add Image

7。 点击添加图片

如何在Tableau中构建自定义地图可视化

8. Browse for an image and set X Field: Right to 500 and Y Field: Top to 500.

8.浏览图像,然后将X字段:右设置为500,将Y字段:顶部设置为500。

如何在Tableau中构建自定义地图可视化

9. In Columns and Rows, add SUM(X) and SUM(Y), respectively.

9.在“列和行”中,分别添加SUM(X)SUM(Y)

如何在Tableau中构建自定义地图可视化

10. For Marks, add SUM(COUNT) in Color, SUM(Count) in Size, and Position in Label.

10.对于标记,在颜色中添加SUM(COUNT) ,在尺寸中添加SUM( Count) ,在标签中添加位置

如何在Tableau中构建自定义地图可视化

Tableau will then generate this visualization for you:

然后,Tableau将为您生成此可视化文件:

如何在Tableau中构建自定义地图可视化

One of the super powers of data visualization is processing the data and understanding it by just looking at the image. With this visualization, I can communicate to you clearly and easily that ankle and knee injuries are the most common sports injuries for an NBA player, and dizziness and nose injuries are the least common.

数据可视化的超级力量之一就是通过查看图像来处理数据并理解它。 借助这种可视化,我可以轻松方便地向您传达, 踝关节膝盖受伤是NBA球员最常见的运动伤害, 头晕鼻子伤是最不常见的伤害。

Voila! Hope you enjoyed this simple experiment =)

瞧! 希望您喜欢这个简单的实验=)

翻译自: https://www.freecodecamp.org/news/cjn-how-to-build-custom-map-visualization-in-tableau/