Open vitorbaptista opened 5 years ago
A data package is a lightweight standard to describe tabular data. In it's simplest form, it's a datapackage.json file like:
datapackage.json
{ "name": "big-mac-data", "description": "Lorem ipsum", "resources": [ { "name": "big-mac-full-index", "path": "output-data/big-mac-full-index.csv", "schema": { "fields": [ { "name": "date", "type": "date", "constraints": { "required": true } }, // ... ] } } ] }
You can see a full example of a data package at https://github.com/vitorbaptista/birmingham_schools.
There are multiple libraries that understand this format, for example https://github.com/frictionlessdata/goodtables-py allows the data to be validated by running goodtables datapackage.json (this can even be run automatically using https://goodtables.io/), https://github.com/frictionlessdata/datapackage-py allows loading the data in Python (automatically validating and casting the data to their specific types), and there are others for R, JavaScript, Ruby and others.
goodtables datapackage.json
I'd be happy to talk more about it, and/or write a datapackage.json and send a PR.
(cc @serahrono @pwalsh)
A data package is a lightweight standard to describe tabular data. In it's simplest form, it's a
datapackage.json
file like:You can see a full example of a data package at https://github.com/vitorbaptista/birmingham_schools.
There are multiple libraries that understand this format, for example https://github.com/frictionlessdata/goodtables-py allows the data to be validated by running
goodtables datapackage.json
(this can even be run automatically using https://goodtables.io/), https://github.com/frictionlessdata/datapackage-py allows loading the data in Python (automatically validating and casting the data to their specific types), and there are others for R, JavaScript, Ruby and others.I'd be happy to talk more about it, and/or write a
datapackage.json
and send a PR.(cc @serahrono @pwalsh)