mario.parse_eurostat#
- mario.parse_eurostat(country: str, year: int, table: str = 'SUT', iot_mode: str = 'product', unit: str = 'MIO_EUR', path: str | None = None, download: bool = False, overwrite_download: bool = False, model: str = 'Database', name: str = None, calc_all: bool = False, timeout: int = 60, **kwargs) object#
Parse Eurostat national tables directly from the official SDMX API.
This parser targets the official national Eurostat supply-use and input-output datasets exposed through the SDMX API, not arbitrary local spreadsheets.
Eurostat availability is year- and country-dependent. In general:
SUTtables are annual and published from reference year2010onward;IOTtables are published from reference year2010onward, but mandatory transmission is only five-yearly for years ending with0or5;additional
IOTyears depend on voluntary country transmission.
- Parameters:
country (str) – Eurostat geo code, for example
ITorDE.year (int) – reference year to download.
table (str, optional) – target table family, either
SUTorIOT.iot_mode (str, optional) – Eurostat IOT layout when
table='IOT'. Supported values areproductfor product-by-product andindustryfor industry-by-industry tables.unit (str, optional) – Eurostat SDMX unit code. Supported values are
MIO_EURandMIO_NAC.path (str, optional) – optional directory for locally stored raw Eurostat CSV slices.
download (bool, optional) – when
True, download the raw CSV slice intopathand then parse it locally.overwrite_download (bool, optional) – when
download=True, overwrite already downloaded raw files.model (str, optional) – currently only
Databaseis supported.name (str, optional) – optional database name stored in metadata.
calc_all (bool, optional) – if True, calculate missing derived matrices after parsing.
timeout (int, optional) – request timeout in seconds used for each SDMX call.
References
Eurostat metadata and dataset context: https://ec.europa.eu/eurostat/cache/metadata/en/naio_10_n_esms.htm
Eurostat API guide: https://ec.europa.eu/eurostat/web/user-guides/data-browser/api-data-access/api-introduction