Using the Data Interpreter and pivot
In this recipe, we will clean up the following spreadsheet on Canada international student permits and ready it for Tableau:
Getting ready
To follow this recipe, download the file from the Citizenship and Immigration Canada website using the following URL:
http://www.cic.gc.ca/opendata-donneesouvertes/data/IRCC_IS_0004_E.xls
How to do it...
Here are the steps to clean up the file:
Connect to the Excel file in this recipe. Make sure you choose Excel from the To a File section:
Check the checkbox beside Use Data Interpreter. Note that when this checkbox is checked, the label changes to Cleaned with Data Interpreter:
Select all fields except for Destination.
While the fields are selected, right-click and choose Pivot:
Right-click the new fields to rename them:
Change Pivot Field Names to Period
Change Pivot Field Values to International Students
Click on Add underneath Filters:
In the Select a field: option, choose Period:
In the filter window for Period, under the...