Description Usage Arguments Examples
View source: R/get_player_stats_individual.R
Returns a data frame of players, their bio information (age, birth place, etc.), and career statistics for user supplied player URLs and names.
1 2 | get_player_stats_individual(..., progress = TRUE,
strip_redundancy = TRUE, other = "")
|
... |
Function requires a |
progress |
Sets a Progress Bar. Defaults to |
strip_redundancy |
Removes variables |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | # The function works in conjunction with get_teams() and get_player_stats_team()
teams <- get_teams("ohl", 2018)
stats_team <- get_player_stats_team(teams)
get_player_stats_individual(stats_team)
# The function also works in conjunction with get_drafts()
drafts <- get_drafts("nhl entry draft", 2018)
get_player_stats_individual(drafts)
# All functions are easily pipeable too
get_teams(c("shl", "allsvenskan"), 2009:2011) %>%
get_player_stats_team(progress = TRUE) %>%
get_player_stats_individual(strip_redundancy = FALSE)
# It's also easy to get player stats & bio information for only 1 team
get_teams("ncaa iii", 2018) %>%
filter(team == "Hamilton College") %>%
get_player_stats_team() %>%
get_player_stats_individual()
# Once you have your data, use tidyr::unnest() to view players' career statistics
get_teams("ncaa iii", 2015) %>%
filter(team == "Hamilton College") %>%
get_player_stats_team() %>%
get_player_stats_individual() %>%
tidyr::unnest(player_statistics)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.