Description Usage Arguments Details Value See Also Examples
Retrieves the player biography data from stats.nba.com subject to the filters recognised by statsnbaR, and returns it as a data.frame.
1 | get_bio(filters = filter_bio(), method = NULL, ...)
|
filters |
A named list of key-value filters constructed by
|
method |
Optional user-supplied function to retrieve JSON from stats.nba.com |
Provides player data given as per-season measurements. For a given league and season, this will return basic and advanced statistics for all the active players.
The query filters are constructed by the filter_bio
function.
The list of filters available is given in the documentation for that
constructor. The units that the values/data is aggregated into is determined
by the per
filter, which can be set to either total
for the
total values or game
for per-game values. This won't affect the
percentage statistics returned.
The filters may include season segments, such as the playoffs, date filters or versus opponents and so on, and the values returned will reflect the performance and data collected in only those selected periods or whatever filter is applied.
A data.frame containing the player biography data with columns converted to the data types specified by statsnbaR's internal YAML.
integer - ID of the player, used in many other datasets
character - the player's first and last name
integer - the team_id
of the team the player plays for
according to the season selected (see filter_bio
)
character - abbreviated team name
integer - age of player in the season selected (see
filter_bio
)
integer - listed player height in inches
integer - listed player weight in lbs
character - name of college or prior affiliation
character - name of country of origin of player
integer - year player was drafted (NA if undrafted)
integer - round player was drafted in (NA if undrafted)
integer - number player drafted at (NA if undrafted)
numeric - games played within the selected filters
All other returned columns are described in the glossary provided at http://stats.nba.com/help/glossary.
http://stats.nba.com/help/glossary/
1 2 3 4 5 | ## Not run:
df <- get_bio(filter_bio(season=2014))
tail(df)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.