2023: Week 46 - Late For School

 Challenge by: Adrien Sourdille

This challenge is the penultimate of the ongoing series related to “Prep” School provided by DS38. Over to Adrien to explain the challenge:

As the Prep School principal, you have heard worrying reports about some of your students being constantly late to class. Naturally, you want to investigate these rumors and get to the bottom of what is happening in your establishment. Luckily, your pupils need to swipe their student cards to enter the building every morning. The attendance log you have access to describes the daily arrival time of 8 students for the year 2022. Null values are generated if the student is absent that day. 

You are particularly interested in understanding on what day of the week your students are the latest and which students are “very late” (more than 5 minutes) the most often. 

Input

1 input this week with card entry data

Requirements

  • Input data
  • Exclude null values from the Arrival Time field. These are days the student wasn't present
  • Turn the Scheduled Start Time and Arrival Time fields into Date Time fields
  • Calculate how many minutes late each student is each day
    • If they arrive before the Scheduled Start Time, they'll have a negative value for this field
  • Rank the days of the week in order of Average Lateness
  • Convert the Average Lateness into 2 fields: 1 for Minutes and 1 for Seconds
  • Create Output 1
  • Rank the students by the percentage of days they were “very late” (more than 5 minutes) during the year
  • Create Output 2

Outputs

Output 1

  • 4 fields
    • Rank
    • Day of the Week
    • Minutes Late
    • Seconds Late
  • 5 rows 

Output 2

  • 3 fields
    • Rank
    • Student ID
    • % Days Very Late
  • 8 rows
After you finish the challenge make sure to fill in the participation tracker, then share your solution on Twitter using #PreppinData and tagging @Datajedininja@JennyMartinDS14 & @TomProwse1

You can also post your solution on the Tableau Forum where we have a Preppin' Data community page. Post your solutions and ask questions if you need any help! 

Popular posts from this blog

2024: Week 1 - Prep Air's Flow Card

2023: Week 1 The Data Source Bank

How to...Handle Free Text