Description Usage Arguments Value Examples
This function retrieves the specified data source. Use searchEndpoints
to see valid options for the endpoint parameter (these are the available datasets) and
getEndpointParams
to learn what parameters are needed to pass in as the
params argument for the chosen endpoint.
1 | getGenericData(endpoint, params = list())
|
endpoint, |
endpoint to retrieve as a character vector |
params, |
list of parameters |
A data frame or a list of data frames (if the endpoint returns multiple datasets) containing the requested data.
1 2 3 4 5 6 7 8 9 | player.info.endpoint <- "commonplayerinfo"
player.info.params <-list(PlayerID=201939,IsOnlyCurrentSeason=0,LeagueID="00",Season="2015-16")
player.info <- getGenericData(player.info.endpoint, player.info.params)
str(player.info)
######
game.log.endpoint <- "playergamelog"
game.log.params <- list(PlayerID = 201939, Season = "2015-16", SeasonType = "Regular+Season")
game.log <- getGenericData(game.log.endpoint, game.log.params)
str(game.log)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.