2023: Week 41 - An International School
Created by: Adrien Sourdille
This fundamental tableau prepping challenge comes from DS38 - Adrien Sourdille. Over to Adrien to explain the challenge:
“Because I studied in a bilingual school, I grew up in an international environment where my classmates had very varied origins. The number of nationalities represented in my classroom always baffled me and is the inspiration for this challenge.”
Your task is to group students by nationality and figure out what nationality is the most represented within each classroom.
Input
Requirements
Join both datasets on the Student ID (p.s. you shouldn't always listen to the requirements :) )
Group Values by Spelling to get rid of spelling mistakes in the Nationality field
Aggregate the dataset to get a count of students within each Nationality and classroom
Create a calculated field to output the Rank of each Nationality by classroom in descending order. Follow this blog to learn how to rank in Tableau prep.
Filter the Dataset to keep the first-ranking Nationality in each classroom
Remove unnecessary fields
Output
- Nationality
- Classroom
- Name