Tableau 简明教程
Tableau - Get Started
在本章中,你将学习 Tableau 中的一些基本操作以熟悉其界面。创建任何 Tableau 数据分析报表涉及三个基本步骤。
In this chapter, you will learn some basic operations in Tableau to get acquainted with its interface. There are three basic steps involved in creating any Tableau data analysis report.
这三个步骤分别是−
These three steps are −
-
Connect to a data source − It involves locating the data and using an appropriate type of connection to read the data.
-
Choose dimensions and measures − This involves selecting the required columns from the source data for analysis.
-
Apply visualization technique − This involves applying required visualization methods, such as a specific chart or graph type to the data being analyzed.
为方便起见,我们使用 Tableau 安装附带的示例数据集,名为 sample - superstore.xls。找到 Tableau 的安装文件夹并转至 My Tableau Repository 。在其下面,你在 Datasources\9.2\en_US-US 处将找到上述文件。
For convenience, let’s use the sample data set that comes with Tableau installation named sample – superstore.xls. Locate the installation folder of Tableau and go to My Tableau Repository. Under it, you will find the above file at Datasources\9.2\en_US-US.
Connect to a Data Source
在打开 Tableau 时,你将获得显示各种数据源的启动页。在标题 “Connect” 下,你可以选择文件、服务器或已保存的数据源。在“文件”下,选择 excel。然后导航到如上所述的文件 “Sample – Superstore.xls” 。excel 文件中有三个工作表,名为“订单”、“人员”和“退货”。选择 Orders 。
On opening Tableau, you will get the start page showing various data sources. Under the header “Connect”, you have options to choose a file or server or saved data source. Under Files, choose excel. Then navigate to the file “Sample – Superstore.xls” as mentioned above. The excel file has three sheets named Orders, People and Returns. Choose Orders.
Choose the Dimensions and Measures
接下来,根据维度和度量选择需要分析的数据。维度是描述性数据,而度量是数字数据。将两者放在一起时,它们有助于可视化维度数据的性能与度量数据的性能。选择 Category 和 Region 作为维度,选择 Sales 作为度量。将它们拖放至以下屏幕截图中所示的位置。结果显示了每个地区在每个类别中的总销售额。
Next, choose the data to be analyzed by deciding on the dimensions and measures. Dimensions are the descriptive data while measures are numeric data. When put together, they help visualize the performance of the dimensional data with respect to the data which are measures. Choose Category and Region as the dimensions and Sales as the measure. Drag and drop them as shown in the following screenshot. The result shows the total sales in each category for each region.
Apply Visualization Technique
在上一步中,您会看到这些数据仅以数字形式提供。您必须阅读和计算每一个值来判断性能。但是,您可以将它们作为图形或带有不同颜色的图表来查看,以更快速地做出判断。
In the previous step, you can see that the data is available only as numbers. You have to read and calculate each of the values to judge the performance. However, you can see them as graphs or charts with different colors to make a quicker judgment.
我们将 Marks 选项卡中的 sum(sales)列拖放到 Columns 区域中。现在,显示销售数字值的表格将自动变成条形图。
We drag and drop the sum (sales) column from the Marks tab to the Columns shelf. The table showing the numeric values of sales now turns into a bar chart automatically.
您可以应用一项技术,即向现有数据添加另一个维度。这会给现有条形图添加更多颜色,如下图所示。
You can apply a technique of adding another dimension to the existing data. This will add more colors to the existing bar chart as shown in the following screenshot.