From the course: Advanced Tableau for Climate Professionals
Join and prepare your climate datasets in Tableau
From the course: Advanced Tableau for Climate Professionals
Join and prepare your climate datasets in Tableau
- [Instructor] So are you ready? Let's begin by joining our two datasets inside Tableau. Open the workbook and go up to the Data pane. Click the Data, click the New Data Source, and choose the text file from the list. You'll see our two ready-to-use datasets. I'll click on the CO2 Data first. It contains CO2 per Capita, CO2 per GDP, Energy per Capita, Energy per GDP, Year, Emissions. Now double-click the CO2 Data queue and bring the Income group file, drag and drop. As you can see, Tableau automatically created a join. We'll join them using two keys, ISO Code and Year. Right now it's only joined by the year. Let's fix that by adding ISO Code for both data source. Click, find ISO Code. Click, Code. Perfect. This ensure a strict match by the post country and year. Why not use country? Because naming conventions vary and we want consistency across all data points. ISO Code is a three letter global standard used by many of official sources. It keeps our data consistent no matter where it comes from. We'll use an inner join to include only records that exists in both dataset for a given year and country. Because our goal is reliability and in climate analytics, this builders can distort per capita or benchmarking KPIs. Let's bring in the join logical table to new data. Go up, click on it. All right, new data. Now go to a new worksheet or go to the worksheet 2.1. With the join complete and the structure online, we are ready to clean and rename the fields. Let's direct the country and entity to the rows, entity and country. For me, using the short version of the country would be more intuitive. So let's rename the fields. Go to the country. Right click on it. Click on rename. I'll call it country long. All right. And then go down, find entity, right click on it. Rename. I will call it country. And make sure the country field also work as a geographic role. So right click on it. Okay, go down. You can find geographic role. Here, we will select Country/Region. Perfect. Now we are ready to jump in the next video.
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.