Using Tableau to Visualize COVID-19 Data
Last updated
Last updated
The Tableau COVID-19 Data Hub contains resources to help people visualize and analyze the most recent data on the coronavirus outbreak.
In this tutorial, we will learn:
How to connect data to Tableau
How to create worksheets
How to create an interactive dashboard
How to save and publish your visualization
In this tutorial, we will work the COVID-19 data from the European Centre for Disease Prevention and Control website.
Data preview in Excel:
The data fields are described below:
Startup Tableau desktop, you will get the start page showing various data sources. Under the “Connect” on the left side of the screen, you have options to connect to a file or server data source. Under to a File, choose Text file. Then navigate to the CSV file you just download from the last step:
At the bottom of the Tableau desktop, click on a sheet (sheet 1) and you will see the following screen:
Tableau automatically separates the data into Dimensions and Measures. Dimensions are the categorical fields. Measures are the quantitative fields, such as death count, positive cases count
We will create a bar chart tracking number of new positive cases per day. Drag “People Positive New Cases” from Measures and drop it into the “Rows” section. Drag" Report Date" from Dimensions to "Columns". Select “Days” from the shortcut menu.
Note that it defaults to YEAR(Date). To format how the date is displayed, right-click on YEAR(Date) and select Day, specifically the option that has the example "8th May, 2015".
We can also add some filters to the bar chart so that a user could filter to see a certain country or date range. From Dimensions, drag Country Short Name to the Filters shelf. Click on All and then OK.
Next, right-click on the Country Short Name on the Filters shelf and select Show Filter. Now you will see a list of countries on the right.
Double click on Sheet 1, rename the worksheet title to "New Positive Cases"
Next, we will create a map. First, open a new workbook, double click "Country Short Name", Tableau has placed the longitude and latitude coordinates in the columns and rows, respectively, a point map will show on the design canvas.
Drag and drop "People Positive Cases Count" to Size under Marks.
Double click on Sheet 2, rename the worksheet title to "New Positive Cases by Country"
Now we will create the third worksheet, open a new worksheet.
We’ll create a vertical bar chart tracking confirmed case per country.
Drag “People Positive Cases Count” from measures and drop it into the “Columns” section. Drag Country Short Name from Dimensions to "Measures".
Go to the bottom of the chart and click on the sorting icon. Sort the number of positive cases in descending order.
Go to Marks, you customize the chart color by using the color pilates.
Name the worksheet “Positive Cases by Country.”
Let’s create a dashboard to pull all of these visualizations together. The dashboard will combine our three visuals we have made in the previous steps. Click on the new dashboard icon at the bottom of the page to create a new dashboard.
Our three worksheets are on the left. Drag “worksheet 1" into the drop area on the right.
Combine 3 worksheets: