2020: Week 53

Challenge by: Jenny Martin

2020 - what a year! Much has changed, few things have stayed the same. Even our star signs weren't safe! The introduction of a 13th star sign, Ophiuchus, threw things into disarray. Were you born on a day where your star sign has remained unchanged? Let's make a list of all those affected by the changes.

Just a quick thank you for those who have stuck with us in 2020, those who joined us in 2020 and all who learnt something new about Prep! 

Inputs

  1. Old Star Signs and Date Range 

  2. New Star Signs and Date Range 

  3. Handy Date Scaffold 

Requirements

  • Input the data. Be careful your data isn't mistaken for a header.
  • Reshape and clean up the data so you have a column for the star sign, along with the start and end dates.
  • Create a date range for the new star signs.
  • Scaffold the data so you have a row for every date of the year (2020 is a good year to base this off, since it's even a leap year!)
  • For the output, we're looking for a list of dates that have changed their star sign. For dates on the cusp, if at least one of their new star signs matches at least one of their old star signs, we consider their star sign not to have changed and so they are excluded from the output.
    • Edit: For example, 19th February is on the cusp in the old world, with a star sign of either Aquarius or Pisces. Its new star sign is Aquarius and so it hasn't necessarily "changed" and should be excluded from the output
  • Create a birthday field.
  • Output the data.

Output

  • 4 fields
    • Birthday
    • Old Star Sign
    • New Star Sign
    • Date Range
  • 313 rows (314 including headers)

The full output can be downloaded here.

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@JonathanAllenby & @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! 

Comments

Popular posts from this blog

How to use... Custom SQL in Prep Builder

2021: Week 1

How to... Aggregate in Prep Builder