readr comes bundled with a number of sample files in its inst/extdata
directory. This function make them easy to access
readr_example(file = NULL)Name of file. If NULL, the example files will be listed.
readr_example()
#> [1] "challenge.csv" "chickens.csv" "epa78.txt"
#> [4] "example.log" "fwf-sample.txt" "massey-rating.txt"
#> [7] "mtcars.csv" "mtcars.csv.bz2" "mtcars.csv.zip"
#> [10] "whitespace-sample.txt"
readr_example("challenge.csv")
#> [1] "/data/GHE/deployment/deployments/2022-02-15/renv/library/R-4.1/x86_64-pc-linux-gnu/readr/extdata/challenge.csv"