Load TidyTuesday data from Github

tt_load(x, week, download_files = "All", ..., auth = github_pat())

Arguments

x

string representation of the date of data to pull, in YYYY-MM-dd format, or just numeric entry for year

week

left empty unless x is a numeric year entry, in which case the week of interest should be entered

download_files

which files to download from repo. defaults and assumes "All" for the week.

...

pass methods to the parsing functions. These will be passed to ALL files, so be careful.

auth

github Personal Access Token. See PAT section for more information

Value

tt_data object, which contains data that can be accessed via `$`, and the readme for the weeks TidyTuesday through printing the object or calling `readme()`

PAT

A Github PAT is a personal Access Token. This allows for signed queries to the github api, and increases the limit on the number of requests allowed from 60 to 5000. Follow instructions from <https://happygitwithr.com/github-pat.html> to set the PAT.

Examples

# check to make sure there are requests still available if(rate_limit_check(quiet = TRUE) > 10){ tt_output <- tt_load("2019-01-15") tt_output agencies <- tt_output$agencies }
#> --- Compiling #TidyTuesday Information for 2019-01-15 ----
#> --- There are 2 files available ---
#> --- Starting Download ---
#> #> Downloading file 1 of 2: `agencies.csv` #> Downloading file 2 of 2: `launches.csv` #>
#> --- Download complete ---