Use this function to scrape fantasy football projections from Yahoo Sports.
To use this function you will have to set up a Yahoo Sports fantasy league and
specify the league id in the options with options('ffdata.yahoo_league'='leagueid')
1 2 3 4 | scrape_yahoo(stat_type = c("Projected", "Actual", "Remaining Season",
"Next 4 weeks", "Last 4 Weeks", "Avg Last 4 Weeks"), position = c("O", "DP",
"QB", "RB", "WR", "TE", "K", "DST", "D", "DB", "DL", "LB", "DT", "DE", "CB",
"S"), season = NULL, week = NULL)
|
stat_type |
The projection type requested. Has to be one of
|
position |
The player position to scrape data for. Has to be one of
|
season |
The year data should be scraped for. If omitted the current season data will be scraped. |
week |
The week that data will be scraped for. If omitted, season data will be scraped. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.