Checks if a path can be resolved (i.e. whether it exists). An additional
parameter parent.path
can be provided, in which case x
is
appended to it and the concatenated path is checked for existence. If the
path cannot be resolved, raise an error.
check_path(x, parent.path = NULL, require.file = FALSE)
x | Character string path. |
---|---|
parent.path | Character string root path. |
require.file | Logical indicating if a file is required for return or if an existing parent folder is enough |
A cleaned character string