get_team_schedule | R Documentation |
This function returns a data frame of the schedule for the specified team. This will include game ids used for play-by-play scraping if the game has ended, along with the team scores and attendance.
get_team_schedule(
team.id = NA,
season = NA,
team.name = NA,
use_file = F,
save_file = F,
base_path = NA,
overwrite = F
)
team.id |
The unique id given to each college/team for each season. This can be found in the url of the team page. |
season |
Season following format yyy1-y2, ex "2018=19" |
team.name |
Alternative to using the id, you can get a team from data(teamids) with a season and team name specification. This inputs a team name, to be used along with season. This needs the school name not the complete team name, so "Duke" not "Duke Blue Devils". |
data frame with each row representing an individual game
Date - Game date
Home - Home team
Home_Score - If the game is finished, the final score for the home team
Away - Away team
Away_Score - If the game is finished, the final score for the away team
Game_ID - If the game is finished and has play-by-play data available, the game ID used to scrape game data
isNeutral - A logical variable that is true when the game was played at a designated neutral destination
Detail - Additional detail such as if the game went into OT and # of OTs
get_team_schedule(team.id = 450680)
get_team_schedule(season = "2018-19", team.name = "Penn")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.