fetch_player_details {fitzRoy} | R Documentation |
Fetch Player Details
Description
fetch_player_details
returns player details such as date of birth, debut
and other details. The exact details that are returned will depend on which
source is provided.
By default the source used will be the official AFL website.
fetch_player_details_afl()
, fetch_player_details_afltables()
and fetch_player_details_footywire()
can be called directly and return data from the AFL website, AFL Tables and Footywire respectively.
The function will typically be used to return the current team lists. For historical data, you can use the current
argument set to FALSE. This will return all historical data for AFL.com and Footywire data. AFLTables data will always return historical data.
Usage
fetch_player_details(
team = NULL,
current = TRUE,
comp = "AFLM",
source = "AFL",
...
)
fetch_player_details_afl(
season,
team = NULL,
comp = "AFLM",
official_teams = FALSE
)
fetch_player_details_afltables(team = NULL)
fetch_player_details_footywire(team, current = TRUE)
Arguments
team |
team the player played for in the season for, defaults to NULL which returns all teams |
current |
logical, return the current team list for the current calendar year or all historical data |
comp |
One of "AFLM" (default) or "AFLW" |
source |
One of "AFL" (default), "footywire", "afltables" |
... |
Optional parameters passed onto various functions depending on source. |
season |
Season in YYYY format |
official_teams |
boolean, defaults to FALSE. Indicates if we should match |
Value
A Tibble with the details of the relevant players.
See Also
-
fetch_player_details_afl for AFL.com data.
-
fetch_player_details_footywire for Footywire data.
-
fetch_player_details_footywire for AFL Tables data.
Examples
## Not run:
# Return data for current Hawthorn players
fetch_player_details("Hawthorn")
fetch_player_details("Adelaide", current = FALSE, comp = "AFLW")
fetch_player_details("GWS", current = TRUE, csource = "footywire")
## End(Not run)