pyerviss¶
Weekly influenza-like illness (ILI), acute respiratory infection (ARI) and severe acute respiratory infection (SARI) rates for EU/EEA countries, and test positivity for influenza, RSV and SARS-CoV-2, as pandas DataFrames.
pyerviss gives Python access to data from ERVISS, the European Respiratory Virus Surveillance Summary, with history back to 2014 (ILI, ARI, primary care positivity) and 2020 (SARI).
Important
pyerviss is an independent, unofficial project. It is not affiliated with, endorsed by, or maintained by the European Centre for Disease Prevention and Control (ECDC) or ERVISS. The data is processed here (see Data sources and updates and Units) and can differ from the official figures. For official data, see erviss.org.
Installation¶
pip install pyerviss
Requires Python 3.10 or later.
Quickstart¶
import pyerviss as pv
# ILI rates for Italy and Malta in the 2024/25 season, all ages combined
df = pv.get_ili(countries=["Italy", "MT"], season="2024/25", age_groups="total")
indicator country country_code year_week date age value unit
0 ili Italy IT 2024-W42 2024-10-20 total 592.8 per 100,000 population
1 ili Italy IT 2024-W43 2024-10-27 total 583.4 per 100,000 population
...
To try it without installing anything, open the quickstart notebook in Colab.
The first call downloads the data (a few MB) and caches it; later calls are fast and work offline. See Querying data for all filters and Units before comparing countries.
Contents¶
Querying data: countries, weeks, seasons, age groups and the output format
Positivity: influenza, RSV and SARS-CoV-2 test positivity, and combining it with ILI/ARI/SARI
Past vintages (backtesting): data as published on a past date, for backtesting forecasts
Plotting: season charts, comparing countries and age groups, positivity with confidence bands
Units: what each value measures, by country (read this before comparing countries)
Data sources and updates: where the data comes from, how it is updated and what differs from ECDC
Caching and offline use: local cache, updates and offline use
API reference: reference for every public function