PyPI version 0.1.0
This is an update to the PyPI package delphi-epidata
, which can be found at https://pypi.org/project/delphi-epidata/.
This version includes explicit client and server version management, limited retry support to work around transient server problems in covidcast, and as_of support for the covid_hosp
endpoint.
It can be installed like this:
pip install delphi-epidata
Sample usage:
# import
from delphi_epidata import Epidata
import json
# query
print(json.dumps(Epidata.covid_hosp("pa", 20201101, as_of=20201201), indent=2))
{
"epidata": [
{
"state": "PA",
"issue": 20201116,
"date": 20201101,
"critical_staffing_shortage_today_yes": null,
"critical_staffing_shortage_today_no": null,
[...]
"inpatient_bed_covid_utilization": 0.04931332373463285,
"adult_icu_bed_covid_utilization": 0.110148849797023,
"adult_icu_bed_utilization": 0.7511181268087346
}
],
"result": 1,
"message": "success"
}