View source: R/opendatapackage.R
opendatapackage | R Documentation |
Open a data package
opendatapackage(path, readonly = TRUE)
path |
The filename or the data package description or the directory in which the data package is located. |
readonly |
Open the data package as a read-only data package or not. See 'details' |
When path
is a directory name, the function looks for the files
'datapackage.json' or 'datapackage.yaml' in the directory. Otherwise, the
function assumes the file contains the description of the data package.
When the data package is read with readonly = FALSE
, any operations
reading properties from the data package read those properties directly from
the file on disk. And setting the properties will change the file on disk.
This ensures the file is always consistent.
Returns a list with the contents of the data package when
readonly = TRUE
. Otherwise an empty list is returned. In both cases
the filename of the data package description (typically 'datapackage.json')
and the director in which the data package is located are stored in
attributes of the result.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.