Every Pitch of the 2014 MLB Season Visualized in Tableau

Data

Every Pitch of the 2014 MLB Season Visualized in Tableau

by Robert Rouse
//

As a data geek, it’s hard not to be drawn in by a sport like Major League Baseball with such rich statistics readily available. I wasn’t very interested in the game until I discovered how simple it is to collect and analyze data on every player, pitch and play. This dashboard is the result of my discovery:

Getting the Data

All the data for this viz comes from PITCHf/x, a tracking system installed in every MLB stadium. Fangraphs has an excellent overview of it and how to interpret the data.

An easy way to get data in bulk is the pitchRx package for R by Carson Sievert. I followed the examples he gave for downloading it into a SQLite database. You will need to install a SQLite ODBC driver to get it from there into Tableau.

Bonus Tip: Smooth Colors With Halftone Custom Shapes

To create the heat map, I used a custom shape that provides a smooth transition between differently-colored overlapping marks. Since Tableau doesn’t recognize gradient transparency in custom shapes, we can use halftones (altering the size and spacing of small dots) to achieve the same result. This concept was first used in black-and-white printing to create the impression of gray scales. In Tableau, it creates a “fade” effect on each mark.

The pitching visualization uses the circular halftone below. Download the image and follow the steps here to use it in your own dashboards.

Radial Gradient Halftone

More About the Author

Robert Rouse

Analytics Consultant
Eine neue Art KPIs in Tableau zu visualisieren Key Performance Indicators sind eines der Dinge, die Leute am häufigsten in Tableau darstellen möchten. Das bezieht für gewöhnlich ein, ...
Disney Data & Analytics Conference 2019 in Review At Disney World, every park has a theme. What you may not know is that their annual data and analytics conference has a theme, too. In ...

See more from this author →

InterWorks uses cookies to allow us to better understand how the site is used. By continuing to use this site, you consent to this policy. Review Policy OK

×

Interworks GmbH
Ratinger Straße 9
40213 Düsseldorf
Germany
Geschäftsführer: Mel Stephenson

Kontaktaufnahme: markus@interworks.eu
Telefon: +49 (0)211 5408 5301

Amtsgericht Düsseldorf HRB 79752
UstldNr: DE 313 353 072

×

Love our blog? You should see our emails. Sign up for our newsletter!