Solved!
starter <- function(path, ...) {
# ensure path exists
dir.create(path, recursive = TRUE, showWarnings = FALSE)
# Create directories
dir.create(file.path(path, "data"))
dir.create(file.path(path, "data/raw"))
dir.create(file.path(path, "data/interim"))
dir.create(file.path(path, "data/processed"))
dir.create(file.path(path, "data/external"))
dir.create(file.path(path, "docs"))
dir.create(file.path(path, "models"))
dir.create(file.path(path, "reports"))
dir.create(file.path(path, "graphs"))
dir.create(file.path(path, "utilities"))
dir.create(file.path(path, "src"))
dir.create(file.path(path, "src/data"))
dir.create(file.path(path, "src/analysis"))
# Create files
file.create(file.path(path, "README.md"))
}