Skip to main content

Pandas Data Package Reader

Project description

PyPI Travis

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


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pandas-datapackage-reader-0.16.0.tar.gz (22.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pandas_datapackage_reader-0.16.0-py2.py3-none-any.whl (5.3 kB view details)

Uploaded Python 2Python 3

File details

Details for the file pandas-datapackage-reader-0.16.0.tar.gz.

File metadata

  • Download URL: pandas-datapackage-reader-0.16.0.tar.gz
  • Upload date:
  • Size: 22.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.8.2

File hashes

Hashes for pandas-datapackage-reader-0.16.0.tar.gz
Algorithm Hash digest
SHA256 6a164cb99210e9bef98b0d4c6fa1954e6c7b8b837f4ecf2db0d3c39440481bc1
MD5 5196ce61baf4cf3d6b9ea7f5b0614d1d
BLAKE2b-256 2bd7d9f157287805ab267ce2e14e431488278ef2bc575c938d61675436eb5132

See more details on using hashes here.

File details

Details for the file pandas_datapackage_reader-0.16.0-py2.py3-none-any.whl.

File metadata

  • Download URL: pandas_datapackage_reader-0.16.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.0 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.8.2

File hashes

Hashes for pandas_datapackage_reader-0.16.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ef321c6cf7641ef9e7779020a91bd8206d70da6df67fe389c9ab13eb6a61d445
MD5 27b5f87d6feaba869ccb73d1f5883f38
BLAKE2b-256 341ff1cf3bdf5dfd799904abe846ad667cd9094970bb13f6bc39f894cc701c48

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page