readr comes bundled with a number of sample files in its inst/extdata directory. This function make them easy to access

readr_example(path = NULL)

Arguments

path

Name of file. If NULL, the example files will be listed.

Examples

readr_example()
#> [1] "challenge.csv" "epa78.txt" "example.log" #> [4] "fwf-sample.txt" "massey-rating.txt" "mtcars.csv" #> [7] "mtcars.csv.bz2" "mtcars.csv.zip"
readr_example("challenge.csv")
#> [1] "/Users/jhester/Dropbox/projects/readr/inst/extdata/challenge.csv"