How-To: Visualize your ESPN Fantasy Football Data:
This blog post will be focused on how you can use my new Tableau fantasy football dashboard with your own ESPN fantasy football league. Subsquent posts will examine the dashboards within the package, and how I created them in Tableau. Shoutout to Tom O'Hara for pushing me to complete this bootstrap, to Adam Crahen and Ryan Sleeper for the peer reviews of the workbook ,and to Rody Zakovich for help with the arcs in the workbook.
This bootstrap is structured to use ESPN fantasy football league. The excel template contains a macro that will streamline the data wrangling process. The macro is set up to format leagues with the positions shown below. The file can be modified to accommodate other league formats, please let me know if you need help! Note, while this package is set up to work with ESPN data, data from other fantasy leagues can use this Tableau workbook if you structure your data in the table format on the “Data” tab of the excel file.
1 – QB
2 – RB
2 – WR
1 – TE
1 – FLEX
1 – D/ST
1 – K
6 – Bench
Step 1: Log into your fantasy league and navigate to the ESPN quick box score for the desired week.
Step 2: Click on the “show bench” option to see the entire quick box score.
Step 3: Highlight the entire box score and copy the data.
Step 4: Navigate to the excel template “Dump” tab. Place your cursor on cell A1 and then paste the data, overwriting any existing data.
Step 5: Run the macro “BoxCleanandCopy”. Note, this macro will automatically create and delete a temporary sheet in the excel file (Temp_2). When prompted select delete.
When the macro is complete, it will automatically take you back to the “Dump” tab. The macro will have added the data to the bottom of the “Data” tab.
Step 6: Repeat steps 2-5 for each matchup of the week.
Step 7: Navigate to the “Data” tab. Manually add the week number (1,2,3,etc.) to Column “K” and add the number “1” to each row in column “L” (this 1 enables joins for the use of arcs in the workbook).
Step 8: Save the excel file and update your Tableau workbook.
While this does require a manual copy and paste, it only took about 5 minutes a week for me to update a 12 team league. If anyone was a better way than copy/paste to automate the data collection process from ESPN please reach out. Files to download and screenshot with instructions below.
Please feel free to reach out with any questions @CoreyJ34 on Twitter.
Files for Download
Download the Tableau file and 3 excel files. The Excel file espn fantasy football package is the main data source. The other two files are used to enable some of the visuals, and are joined using left joins. See image below of connection in Tableau.
Corey's 2016 Fantasy Football Dashboard