1

2023 Week 20 | Power BI: Remake of Tableau Length of Baseball Games

 7 months ago
source link: https://workout-wednesday.com/pbi-2023-w20/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Introduction

For this Workout Wednesday, we are putting a Power BI spin on a Tableau viz created by Luke Stanke and Spencer Bauke for their Workout Wednesday 2023 Week 14

While we could probably match nearly exactly to the original Tableau viz by using Deneb in Power BI, I wanted to see what I could do with just the default visuals. You can choose how you want to do the exercise, but I thought it was a good test of skills to use the built-in small multiples functionality in the stacked column chart. 

If you use both Power BI and Tableau, feel free to try the exercise in both tools and share your observations about differences in the creation experience. 

Requirements

  • Use the Web connector to retrieve the data from https://www.baseball-reference.com/leagues/majors/misc.shtml (Note: you’ll need to find the correct table to import and then use your Power Query skills to shape it up to what you want.)
  • Filter the data to include only years 1960 – 2023. 
  • Create a column chart showing annual average 9-inning game length that has one bar per year, with each decade on a separate row. 
  • Use the field named [Time/9I] as the measure of 9-inning game length. Many of the other columns will not be used in the visual. 
  • Order the bars in ascending chronological order.
  • Place labels inside the bars that show the year and the average time per 9 innings formatted as h:mm. 
  • Create a reference line that matches the average game time for 2023. Label the line with the year and the average time per 9 innings formatted as h:mm. 
  • If the average time for a year is equal to or greater than the 2023 average time, color it orange, if it is less than the average game time in 2023 then color it blue.

Dataset

This week’s data comes from Baseball Reference. Use the following URL to access the League Year-By-Year Miscellaneous table: https://www.baseball-reference.com/leagues/majors/misc.shtml

Share

After you finish your workout, share on Twitter using the hashtags #WOW2023 and #PowerBI, and tag @MMarie, @shan_gsd, @KerryKolosko. Also make sure to fill out the Submission Tracker so that we can count you as a participant this week in order to track our participation throughout the year.

Solution


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK