Skip to main content

A Python- and pandas-powered client for Statistical Data and Metadata eXchange

Project description

pandaSDMX is an Apache 2.0-licensed Python package aimed at becoming the most intuitive and versatile tool to retrieve and acquire statistical data and metadata disseminated in SDMX format. It should work with all SDMX data providers supporting SDMX 2.1. Currently, this is tested for the European statistics office (Eurostat), and the European Central Bank (ECB) each providing hundreds of thousands of indicators.

While pandaSDMX is extensible to cater any output format, it currently supports only pandas, the gold-standard of data analysis in Python. But from pandas you can export your data to Excel and friends.

Main features

  • intuitive API inspired by requests

  • support for many SDMX features including

    • generic datasets

    • data structure definitions, codelists and concept schemes

    • dataflow definitions

    • categorisations and category schemes

  • pythonic representation of the SDMX information model

  • find dataflows by name or description in multiple languages if available

  • read and write files including zip archives for offline use

  • writer transforming SDMX generic datasets into multi-indexed pandas DataFrames or Series of observations and attributes

  • extensible through custom readers and writers for alternative input and output formats of data and metadata

Example

>>> from pandasdmx import Request
>>> # Get annual unemployment data from Eurostat
>>> une_resp = Request('ESTAT').get(resource_type = 'data', resource_id = 'une_rt_a')
>>> # From the received dataset, select the time series on Greece, Ireland and Spain, and write them to a pandas DataFrame
>>> une_df = une_resp.write(s for s in une_resp.msg.data.series if s.key.GEO in ['EL', 'ES', 'IE'])
>>> # Explore the DataFrame
>>> une_df.columns.names
>>> une_df.columns.levels[0:2]
>>> une_df.loc[:'2006', ('TOTAL', 'T')]

Version 0.2.1 (2015-04-22)

  • API: add support for zip archives received from an SDMX server. This is common for large datasets from Eurostat

  • incidentally get a remote resource if the footer of a received message specifies an URL. This pattern is common for large datasets from Eurostat.

  • allow passing a file-like object to api.Request.get()

  • enhance documentation

  • make pandas writer parse more time period formats and increase its performance

Version 0.2.0 (2015-04-13)

This version is a quantum leap. The whole project has been redesigned and rewritten from scratch to provide robust support for many SDMX features. The new architecture is centered around a pythonic representation of the SDMX information model. It is extensible through readers and writers for alternative input and output formats. Export to pandas has been dramatically improved. Sphinx documentation has been added.

v0.1 (2014-09)

Initial release

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

pandaSDMX-0.2.1.tar.gz (52.1 kB view details)

Uploaded Source

Built Distributions

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

pandaSDMX-0.2.2-py2.py3-none-any.whl (97.0 kB view details)

Uploaded Python 2Python 3

pandaSDMX-0.2.1-py3.4.egg (116.0 kB view details)

Uploaded Egg

pandaSDMX-0.2.1-py2.py3-none-any.whl (88.0 kB view details)

Uploaded Python 2Python 3

File details

Details for the file pandaSDMX-0.2.1.tar.gz.

File metadata

  • Download URL: pandaSDMX-0.2.1.tar.gz
  • Upload date:
  • Size: 52.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pandaSDMX-0.2.1.tar.gz
Algorithm Hash digest
SHA256 01445c53c35f5b8b5f7caf8cac94e68dfb9c1c4b76b975ddef2e7e0d75bb0dd9
MD5 24bd692cd1f2021f27b776bb3fec18e4
BLAKE2b-256 315dcba41b963b57173aca22ae34756d7804ba3cb2a926de3f4509502e635a7f

See more details on using hashes here.

File details

Details for the file pandaSDMX-0.2.2-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for pandaSDMX-0.2.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 6454c9130b3cfc902389d7571a7ebcc05ea4bccd051d3a0805984a4339bdb5b5
MD5 025b65b44cbef394c88180a4873f2187
BLAKE2b-256 df99bbeb6e08293ddaf29f3c4f107cd8aa701265176acc39d7b3a75949c402c1

See more details on using hashes here.

File details

Details for the file pandaSDMX-0.2.1-py3.4.egg.

File metadata

  • Download URL: pandaSDMX-0.2.1-py3.4.egg
  • Upload date:
  • Size: 116.0 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pandaSDMX-0.2.1-py3.4.egg
Algorithm Hash digest
SHA256 602a266bfb815cf4833aeac84e952ae0a1512c2aec534e8a0df913b0bf41f5cd
MD5 7b1ff870cac73d88750ef7258fa3b0e1
BLAKE2b-256 beb9fe5e906efc16237949cdb145373acca7d612f9df1b9acaa55a5bddc80835

See more details on using hashes here.

File details

Details for the file pandaSDMX-0.2.1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for pandaSDMX-0.2.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 0e96ad63623af34899afbeebe833d8d764d41a39e343bb4c95e72b7ceecf6a52
MD5 ff04b866f0500b837e4114e4c9d9e859
BLAKE2b-256 caa79c7df3a592b5875a2c753272bf304e33323683a6f5dbfbabdf0aceac239a

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