Description Usage Arguments Details Value Examples
Retrieves current and historical player data from stats.nba.com
1 | get_players(league, season, method = NULL, ...)
|
league |
A character value of league, current recognised values are:
|
season |
Numeric value of the base season, e.g. 2015 for the 2015-2016 season and so on. |
method |
Optional user-supplied function to retrieve JSON from stats.nba.com |
Retrieves basic information about players that stats.nba.com contains in
their dataset for a given league
and given season
. Basic
information is the player's current team, and their first and final
years in the league and so on. The team_id
and person_id
values
returned should be unique for each team and player respectively, so these are
useful keys to other data.
A data.frame with names of current and historical players and the fields
integer - ID of the player, used in many other datasets
character - the player's first name
character - the player's last name
logical - currently rostered in the selected season
integer - year player entered NBA
integer - year player exited NBA
integer - ID of the player's team in the season (if roster_status is true)
character - city of the player's team in the season (if roster_status is true)
character - name of the player's team in the season (if roster_status is true)
character - abbrev. name of player's team (if roster_status is true)
logical - did the player record at least one game in
NBA at any time (even after the selected season
)
1 2 3 4 5 | ## Not run:
df <- get_players(season=2014, league='d-league')
tail(df)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.