Easily access example data.

tor_example(path = NULL)

Arguments

path

Length-1 character vector. A path to an available directory.

Value

A character string listing available directories or a length-1 string giving a path to a directory.

Author

Copied from readr_example() from the readr package, by Jim Hester and colleagues.

Examples

tor_example()
#> [1] "csv" "mixed" "rdata" "rds" "tsv"
tor_example("csv")
#> [1] "/home/runner/work/_temp/Library/tor/extdata/csv"
dir(tor_example("csv"))
#> [1] "csv1.csv" "csv2.csv"