For R packages containing data in the data-raw dir, the usethis.R is written in the same directory, the data is documented in the R/data.R, and devtools::document is run on the contents of the provided path.

document_data(path = getwd())

Arguments

path

Path to the package root that contains the data-raw/, data/, and R/ folders. `