This web map is an open source version of the COVID-19 global cases website by Johns Hopkins CSSE. It uses OpenLayers for mapping, Plotly.js for plotting, and Iconify for icons.
As of December 10, 2020, I stopped updating my demo site because, unfortunately, there is too much data to process and upload to the server. Also, the client-only model doesn't seem to work smoothly at this point. It became too slow to be practical. It wasn't expected at all when I started writing this code early this year.
Single-country maps are now supported:
As of March 27, 2020 at 6pm EDT, fetch_data.py
's count of the United States cases is 697 greater than CSSE's. I checked individual states and created the following table:
County | State | CSSE CSV | CSSE REST |
---|---|---|---|
Coffee | Alabama | 1 | 0 |
Fairbanks North Star | Alaska | 11 | 10 |
Cleburne | Arkansas | 47 | 46 |
Dawson | Georgia | 3 | 2 |
Unassigned | Hawaii | 8 | 6 |
Bannock | Idaho | 3 | 2 |
Bingham | Idaho | 2 | 1 |
Unassigned | Illinois | 668 | N/A |
LaSalle | Illinois | 3 | 0 |
Logan | Illinois | 1 | 0 |
Ascension | Louisiana | 91 | 90 |
Morehouse | Louisiana | 3 | 2 |
Jackson | Michigan | 17 | 16 |
Newaygo | Michigan | 2 | 1 |
Amite | Mississippi | 1 | 0 |
Houston | Tennessee | 3 | 2 |
Guadalupe | Texas | 9 | 8 |
Walker | Texas | 3 | 2 |
Unassigned | Vermont | 8 | 6 |
Norfolk | Virginia | 9 | 8 |
Fairfax City | Virginia | 1 | 0 |
Unassigned | Washington | 69 | 67 |
Preston | West Virginia | 2 | 1 |
Ohio | West Virginia | 2 | 1 |
Hancock | West Virginia | 1 | 0 |
Data from the REST API is supposed to be current because their web map directly uses this data for visualization, but some of those numbers are decreasing for some counties in the United States. I have no idea which version to trust more between their daily reports vs. REST data.
- Create and secure your Bing Maps key at https://www.bingmapsportal.com/
- Copy
config-example.py
toconfig.py
- Set
bing_maps_key
andbing_maps_referer
(your secured URL from step 1) - Set
app_url
to your covid-19 web map URL - Set
use_local_data_only
toTrue
if you don't want to fetch remote data and just want to use files in the data folder - Add country names to
countries_to_display
to save data only for those countries
- Main data source: CSSE's time series data and REST API
- China: DXY
- South Korea: KCDC
- Italy: StatisticheCoronavirus
- Chile: Minsal
I found CSSE's data unreliable because they keep changing country names and adding duplicate entries with incomplete records. I am trying to clean up their data as much as possible to avoid double counting (e.g., as of March 17, Guam vs. Guam, US and French Guiana vs. French Guiana, France), so there can be some discrepancy between my cleaned up data and their original data.
- geodata.json: GeoJSON file with case locations and time series data
- data.csv: CSV file with the same information in a tabular format
Data that fetch_data.py
collects from various data sources is copyrighted by its original owners. Post-processing of the data by the script may introduce errors and the author is not responsible for any damages caused by using the processed data and the web map.
Copyright (C) 2020, Huidae Cho <https://idea.isnew.info/>
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>.