In this tutorial, we will walk you through how to track Covid-19 infection risk with local forecasts and a weather API.
The Covid-19 pandemic has been called the black swan that no one saw coming, taking the world by storm. While each country fights to stop the spread of the disease among their people using information and advice from the WHO, a new Harvard study shows that there may be a connection between weather conditions and the rate of the spread.
To sum up the study, it states that certain environmental factors might have an impact on the transmission rate of Covid-19.
These factors include:
The study captured these fields in their _Relative COVID-19 Risk due to Weather and Air Pollution _(CRW).
“CRW compares the relative changes in reproductive number for the disease due to weather factors (average and diurnal temperature, ultraviolet (UV) index, humidity, pressure, precipitation) and air pollutants (SO2 and Ozone). For example, a shift over a season in CRW from 1 (the 95 percentile in our sample) to 0.7 in a given location points to a 30% reduction in estimated reproduction number over that period due to weather and air pollutants (i.e. assuming everything else is constant).”
Based on this information, I decided to make a web application that shows how to track the value of these factors for different geographical locations. The application will be the world map and when the user clicks on a certain location, the app will place a marker in that spot, and inside a card will show the current value for fields presented in the study.
A demo can be seen in the next
As you've probably already guessed, we need an API from which we can acquire the weather data and map of the world.
For weather data, we’ll use ClimaCell Weather API, because it provides all the required environmental factors and for the map, we’ll use Open Street Map. This map API is not that powerful and easy to use and customize as the map from Google or other tools, but the benefit it has compared to the others is that it is the only one that can be used for free, is an open-source project.
To make things simpler for you I already wrote the code for this map including the marker and the click event and I wrapped it up together with the boilerplate for this project in a zip file.
The first step is to download the code from that zip file and create a free account on ClimaCell to receive an API key.
Weather APIs, powered by technology, provide weather data (some real-time, some at specific times). These data can influence personal decisions and business decisions. There are also numerous APIs that offer Air Quality information. Each with their own features which makes one better than the other.
Learn what are the most important API security threats engineering leaders should be aware of and steps you can take to prevent them
I’ve been working with Restful APIs for some time now and one thing that I love to do is to talk about APIs.
The method used for this initial research was to obtain a list of the ASX100 (as of 18 September 2020). Then work through each company looking at the following
The API development platform provider has launched an API resource center for tapping COVID-19 data including testing location information throughout the U.S.