datapackage | R Documentation |
Read and write data frames to/from 'data-package' format. For reading supported paths are disk, http or git. For writing only disk is supported.
datapkg_read(path = getwd()) datapkg_validate(path = getwd()) datapkg_write(data, name, path = getwd())
path |
file path or URL to the data package directory |
data |
a data frame to be added to the package |
name |
what to name this dataset |
http://frictionlessdata.io/data-packages, https://github.com/datasets
# Create new data package pkgdir <- tempfile() datapkg_write(mtcars, path = pkgdir) datapkg_write(iris, path = pkgdir) # Read it back mypkg <- datapkg_read(pkgdir) print(mypkg$data$mtcars) # Clone package with git: cities <- datapkg_read("git://github.com/datasets/world-cities") # Read over http euribor <- datapkg_read("https://raw.githubusercontent.com/datasets/euribor/master")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.