Downloading FantasyPros Fantasy Football Projections in R
8In this post, I will show you how to download FantasyPros fantasy football projections using R. The key advantage of FantasyPros is that it aggregates many sources of projections into its predictions, which increases prediction accuracy, as I discuss here.
The R Script for downloading fantasy football projections from FantasyPros is located at: https://github.com/FantasyFootballAnalytics/FantasyFootballAnalyticsR/blob/master/R%20Scripts/Projections/FantasyPros%20Projections.R
Could not embed GitHub Gist 6382959: Requires authentication
Here’s a density plot of the FantasyPros projections:
Share
i would like to check it out ….
First off: Thanks for introducing me to R, and thanks for showing your methodology instructions. I’ve been pulling all my data by hand and, needless to say, it’s been extremely time consuming.
I have a question for you about your League Settings.R file. I’m editing it for my own needs, but I noticed that you do not include a flex position. In my league, we have a RB/WR/TE flex slot. How would I add this to League Settings.R ?
I forgot to mention: What about D/ST? Thanks again!
Hey Gabriel, the “numQBstarters” variables in the League Settings.R file are for indicating how many minimum starters to retain for the optimization in the Draft Optimizer (http://apps.fantasyfootballanalytics.net/lineupoptimizer). You can specify flex positions in the tool by using the sliders. Mathematically, it’s setting the constraints so that you retain >= the minimum number of starters at each of the flex positions, yet staying within the total number of allowed starters. Does that make sense? I wrote scripts for downloading D/ST info here:
https://fantasyfootballanalytics.net/2013/07/expected-points-by-position-rank-in-fantasy-football.html
It wouldn’t be too difficult to modify the scraping and optimization scripts to include kickers and D/ST. My analysis showed that those positions should be last off the board (https://fantasyfootballanalytics.net/2013/07/expected-points-by-position-rank-in-fantasy-football.html), so my focus was on the other positions.
Hope that helps!
I’m very green to R…having a hard time understanding where your Functions.R and League Settings.R files are? Any help?
Check out Isaac’s Github: https://github.com/isaactpetersen/FantasyFootballAnalyticsR/tree/master/R%20Scripts
Does that help?
I’ve tried several times in the past to use R & GitHub but wasn’t “Getting It”, even after watching some videos on YouTube. I wanted to ask you if have or if you could make a YouTube Video on how to use both as it relates to Scraping Fantasy Football Analytic Stats? I’m sure it would help not only me but many of us who aren’t as bright when it comes to that sort of stuff as well!
Great suggestion! We’ll put this on our to-do list. In the meantime, you might check out this post:
https://fantasyfootballanalytics.net/2014/10/download-run-r-scripts.html