Pandas Data Package Reader
Project description
pandas-datapackage-reader
Easy loading of tabular data from Data Packages into Pandas DataFrames.
Installation
pip install pandas-datapackage-reader
Usage
from pandas_datapackage_reader import read_datapackage
# From GitHub repository
country_codes = read_datapackage("https://github.com/datasets/country-codes")
# From local directory
country_codes = read_datapackage("country-codes")
# Data Package with GeoJSON
geo_countries = read_datapackage("https://github.com/datasets/geo-countries")
Resource metadata from the Data Package is returned as a dictionary in the
_metadata
attribute.
country_codes._metadata
contains
{'format': 'csv',
'name': 'country-codes',
'path': 'data/country-codes.csv',
'schema': {'fields': [{'description': 'Country or Area official Arabic short name from UN Statistics Divsion',
'name': 'official_name_ar',
'title': 'official name Arabic',
'type': 'string'},
{'description': 'Country or Area official Chinese short name from UN Statistics Divsion',
'name': 'official_name_cn',
'title': 'official name Chinese',
'type': 'string'},
# ...
License
BSD-2-Clause, see LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for pandas_datapackage_reader-0.10.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cb3a163fe0e43e05eae730b1039fdcea95beeec0db136ec62de55ddd4e927474 |
|
MD5 | 957c385201d7da0e74e3c529c136b1c1 |
|
BLAKE2b-256 | 55562c6de4ee4f5d3e55cee83ea040db4ff8e1e3388fc5738a5b53d268ae340c |