n2khab_data
folderR/filemanagement.R
fileman_folders.Rd
This function will check for the existence of default data folders,
create them if necessary, and return the path to the n2khab_data
folder.
fileman_folders(root = c("rproj", "git"), path = NA)
root | Character string indicating whether the root folder of the current git repository or the root folder of the current Rstudio project should be used as the folder where you want the data folder structure to be created.
Can be |
---|---|
path | An optional argument to specify a custom path to a folder where you want the data folder structure to be created. Default is |
A character string that gives the absolute path to the n2khab_data/
folder.
In n2khab projects a standardized folder setup is used for binary
data, as explained in the
vignette on data storage (run vignette("v020_datastorage")
).
The functions creates the folders n2khab_data
, n2khab_data/10_raw
and n2khab_data/20_processed
, or prints a message if these already
exist.
The function returns the path to n2khab_data
.
Other functions regarding file management for N2KHAB projects:
checksum()
,
download_zenodo()
,
fileman_up()
,
locate_n2khab_data()
if (FALSE) { fileman_folders() datapath <- fileman_folders(root = "git") }