Statistical Data and Metadata eXchange (SDMX) in Python¶
sdmx
is an Apache 2.0-licensed Python library that implements SDMX 2.1 (ISO 17369:2013), a format for exchange of statistical data and metadata used by national statistical agencies, central banks, and international organisations.
sdmx
can be used to:
explore the data available from data providers such as the World Bank, International Monetary Fund, Eurostat, OECD, and United Nations;
parse data and metadata in SDMX-ML (XML) or SDMX-JSON formats—either:
from local files, or
retrieved from SDMX web services, with query validation and caching;
convert data and metadata into pandas objects, for use with the analysis, plotting, and other tools in the Python data science ecosystem;
apply the SDMX Information Model to your own data;
…and much more.
Get started¶
SDMX was designed to be flexible enough to accommodate almost any data. To do this, it includes a large number of abstract concepts for describing data, metadata, and their relationships. These are collectively called the “SDMX Information Model” (IM).
This documentation does not repeat full descriptions of SDMX, the IM, or SDMX web services; it focuses on the Python implementation in sdmx
itself.
Detailed knowledge of the IM is not needed to use sdmx
; see a
usage example in only 10 lines of code, and then the longer, narrative walkthrough.
To learn about SDMX in more detail, use the list of resources and references, or read the API documentation and implementation notes for the sdmx.model
and sdmx.message
modules that fully implement the IM in Python.
sdmx
user guide¶
- Data sources
- Data source limitations
ABS
: Australian Bureau of StatisticsESTAT
: EurostatECB
: European Central BankILO
: International Labour OrganizationIMF
: International Monetary Fund’s “SDMX Central” sourceINEGI
: National Institute of Statistics and Geography (Mexico)INSEE
: National Institute of Statistics and Economic Studies (France)ISTAT
: National Institute of Statistics (Italy)LSD
: National Institute of Statistics (Lithuania)NB
: Norges Bank (Norway)NBB
: National Bank of Belgium (Belgium)OECD
: Organisation for Economic Cooperation and DevelopmentSGR
: SDMX Global RegistrySPC
: Pacific Data Hub DotStat by the Pacific Community (SPC)STAT_EE
: Statistics Estonia (Estonia)UNSD
: United Nations Statistics DivisionUNESCO
: UN Educational, Scientific and Cultural OrganizationUNICEF
: UN Children’s FundWB
: World Bank Group “World Integrated Trade Solution”WB_WDI
: World Bank Group “World Development Indicators”
- API reference
- Implementation notes
- How to…
- What’s new?
- Development
Contributing and getting help¶
Ask usage questions (“How do I?”) on Stack Overflow using the tag
[python-sdmx]
.Report bugs, suggest features, or view the source code on GitHub.
The older sdmx-python Google Group may have answers for some questions.