Package: datapackage 0.2.3

Jan van der Laan

datapackage: Creating and Reading Data Packages

Open, read data from and modify Data Packages. Data Packages are an open standard for bundling and describing data sets (<https://datapackage.org>). When data is read from a Data Package care is taken to convert the data as much a possible to R appropriate data types. The package can be extended with plugins for additional data types.

Authors:Jan van der Laan [aut, cre]

datapackage_0.2.3.tar.gz
datapackage_0.2.3.zip(r-4.7)datapackage_0.2.3.zip(r-4.6)datapackage_0.2.3.zip(r-4.5)
datapackage_0.2.3.tgz(r-4.6-any)datapackage_0.2.3.tgz(r-4.5-any)
datapackage_0.2.3.tar.gz(r-4.7-any)datapackage_0.2.3.tar.gz(r-4.6-any)
datapackage_0.2.3.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
datapackage/json (API)
NEWS

# Install 'datapackage' in R:
install.packages('datapackage', repos = c('https://djvanderlaan.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/djvanderlaan/datapackage/issues

On CRAN:

Conda:

datapackagefrictionless

5.40 score 3 stars 56 scripts 552 downloads 73 exports 4 dependencies

Last updated from:da84749696. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK120
source / vignettesOK215
linux-release-x86_64OK118
macos-release-arm64OK76
macos-oldrel-arm64OK150
windows-develOK98
windows-releaseOK86
windows-oldrelOK90
wasm-releaseOK92

Exports:csv_readercsv_writerdp_add_contributordp_add_contributor<-dp_add_readerdp_add_writerdp_apply_schemadp_bytesdp_bytes<-dp_categorieslistdp_check_dataresourcedp_check_fielddp_contributorsdp_contributors<-dp_createddp_created<-dp_descriptiondp_description<-dp_encodingdp_encoding<-dp_fielddp_field_namesdp_formatdp_format<-dp_generate_dataresourcedp_generate_fielddescriptordp_get_connectiondp_get_datadp_get_datapackagedp_hashdp_hash<-dp_iddp_id<-dp_keywordsdp_keywords<-dp_load_from_datapackagedp_mediatypedp_mediatype<-dp_namedp_name<-dp_nresourcesdp_pathdp_path<-dp_propertiesdp_propertydp_property<-dp_resourcedp_resource_namesdp_resource<-dp_resources<-dp_save_as_datapackagedp_schemadp_titledp_title<-dp_to_booleandp_to_codedp_to_datedp_to_datetimedp_to_factordp_to_integerdp_to_numberdp_to_stringdp_to_timedp_to_yeardp_to_yearmonthdp_typedp_type<-dp_write_datafwf_readernew_contributornew_datapackagenew_dataresourceopen_datapackage

Dependencies:iso8601jsonliteRcppyaml

Creating a Data Package

Rendered fromcreating_a_datapackage.mdusingsimplermarkdown::mdweave_to_htmlon May 14 2026.

Last update: 2025-04-14
Started: 2024-01-12

Introduction to datapackage

Rendered fromintroduction.mdusingsimplermarkdown::mdweave_to_htmlon May 14 2026.

Last update: 2025-04-14
Started: 2023-08-13

Overview of support for the Data Package specification v2

Rendered fromsupport.mdusingsimplermarkdown::mdweave_to_htmlon May 14 2026.

Last update: 2025-03-25
Started: 2025-02-03

Readme and manuals

Help Manual

Help pageTopics
Read the CSV-data for a Data Resourcecsv_reader
Write data of data resource to CSV-filecsv_writer
Add a reader function for a specific formatdp_add_reader
Add a writer function for a specific formatdp_add_writer
Convert columns of data.frame to their correct types using table schemadp_apply_schema
Get the a data.frame with the categories for a variable.dp_categorieslist dp_categorieslist.default dp_categorieslist.fielddescriptor
Check if a data set is valid given a Data Resourcedp_check_dataresource
Check if a vector is valid given a field descriptordp_check_field
Get the Field Descriptor associated with a certain field in a Data Resourcedp_field
List the fields in a Data Resourcedp_field_names
Generate Data Resource for a datasetdp_generate_dataresource
Generate a fielddescriptor for a given variable in a datasetdp_generate_fielddescriptor dp_generate_fielddescriptor.character dp_generate_fielddescriptor.code dp_generate_fielddescriptor.Date dp_generate_fielddescriptor.default dp_generate_fielddescriptor.factor dp_generate_fielddescriptor.integer dp_generate_fielddescriptor.logical dp_generate_fielddescriptor.numeric
Get a connection to the data belonging to a Data Resourcedp_get_connection
Get the data belonging to a Data Resourcedp_get_data dp_get_data.datapackage dp_get_data.dataresource
Get the Data Package associated with the objectdp_get_datapackage
Quickly read a dataset from a Data Packagedp_load_from_datapackage
Return the number of resources in a Data Packagedp_nresources
Get a list of properties defined for the objectdp_properties dp_properties.dataresource dp_properties.editabledatapackage dp_properties.fielddescriptor dp_properties.readonlydatapackage dp_properties.tableschema
Get and set properties of Data Packages and Data Resourcesdp_property dp_property.dataresource dp_property.editabledatapackage dp_property.fielddescriptor dp_property.readonlydatapackage dp_property.tableschema dp_property<- dp_property<-.dataresource dp_property<-.editabledatapackage dp_property<-.fielddescriptor dp_property<-.readonlydatapackage dp_property<-.tableschema
Modifying the resources of a Data Packagedp_resource dp_resource.datapackage dp_resource<- dp_resource<-.editabledatapackage dp_resource<-.readonlydatapackage
Get the names of the resources in a Data Packagedp_resource_names
Modify a set of Data Resources in a Data Packagedp_resources<-
Save a dataset as a Data Packagedp_save_as_datapackage
Convert a vector to 'boolean' using the specified field descriptordp_to_boolean
Recode a variable to 'code' using the associated categoriesdp_to_code
Convert a vector to 'date' using the specified field descriptordp_to_date
Convert a vector to 'datetime' using the specified field descriptordp_to_datetime
Recode a variable to factor using the associated categoriesdp_to_factor
Convert a vector to 'integer' using the specified field descriptordp_to_integer
Convert a vector to 'number' using the specified field descriptordp_to_number
Convert a vector to 'string' using the specified fielddescriptordp_to_string
Convert a vector to 'time' using the specified field descriptordp_to_time
Convert a vector to 'year' using the specified field descriptordp_to_year
Convert a vector to 'yearmonth' using the specified field descriptordp_to_yearmonth
Write data of resource to filedp_write_data dp_write_data.datapackage dp_write_data.dataresource
Read the FWF-data for a Data Resourcefwf_reader
Creating and Adding Contributors to a Data Packagedp_add_contributor dp_add_contributor<- new_contributor
Create a new Data Packagenew_datapackage
Create a new Data Resourcenew_dataresource
Open a data packageopen_datapackage
Getting and setting properties of Data Packagesdp_contributors dp_contributors.datapackage dp_contributors<- dp_contributors<-.datapackage dp_created dp_created.datapackage dp_created<- dp_created<-.datapackage dp_description dp_description.datapackage dp_description<- dp_description<-.datapackage dp_id dp_id.datapackage dp_id<- dp_id<-.datapackage dp_keywords dp_keywords.datapackage dp_keywords<- dp_keywords<-.datapackage dp_name dp_name.datapackage dp_name<- dp_name<-.datapackage dp_title dp_title.datapackage dp_title<- dp_title<-.datapackage PropertiesDatapackage
Getting and setting properties of Data Resourcesdp_bytes dp_bytes.dataresource dp_bytes<- dp_bytes<-.dataresource dp_description.dataresource dp_description.fielddescriptor dp_description<-.dataresource dp_encoding dp_encoding.dataresource dp_encoding<- dp_encoding<-.dataresource dp_format dp_format.dataresource dp_format<- dp_format<-.dataresource dp_format<-.fielddescriptor dp_hash dp_hash.dataresource dp_hash<- dp_hash<-.dataresource dp_mediatype dp_mediatype.dataresource dp_mediatype<- dp_mediatype<-.dataresource dp_name.dataresource dp_name<-.dataresource dp_name<-.fielddescriptor dp_path dp_path.dataresource dp_path<- dp_path<-.dataresource dp_schema dp_schema.dataresource dp_title.dataresource dp_title<-.dataresource dp_title<-.fielddescriptor dp_type<-.fielddescriptor PropertiesDataresource
Getting and setting properties of Data Resourcesdp_description<-.fielddescriptor dp_format.fielddescriptor dp_name.fielddescriptor dp_title.fielddescriptor dp_type dp_type.fielddescriptor dp_type<- PropertiesFielddescriptor