A COVID-19 MAP based on Total Death and Total Active Cases on every country in the world by coursera project networks
here is the full line of code covid-map1.ipynb, the dashboard would look like this,
- my-covidmap: https://mariobgsp.github.io/covid-map/
Python modules that i used for this project including,
- json to convert data from API
- folium to generate map in this project
- request & http.client to get Access of the Data via API
- pandas to normalize the data
After importing modules, we're trying to acces Data via API the sites that i'm using for API is from covid19api.com using these line of code, to access data, to convert Data to JSON, and Normalize data using python pandas
imported dataframe would be like this,
you can drop unnecessary columns to make data processing easier, but if you're not just don't (optional)
After that we're trying to generate base map using folium modules, using Stamen Terrain tiles, and trying to obtain geodata from here
full line of code at covid-map.ipynb
Now we're trying to generate choropleth map too, the purpose of choropleth map is to provide an easy way to visualize how measurement (height) varies across a geographic area or show the level of variability region 1
full line of code at covid-map.ipynb
and then we're trying to visualize circular markers which show the total confirmed and total recovered in every country, and merge it with choropleth map.
Datasets of longitude and latitude of every country you can get in here
full line of code at covid-map.ipynb
Choropleth map with circular marker will look like this, the circular markers describe Total Confirmed Case & Total Recovered in every country. full line of code at covid-map.ipynb
Generating Base Map with Black and White colours to make heat map visualize better, and adding a heat map layer, the line of code would be like this,
full line of code at covid-map.ipynb
full line of code at covid-map.ipynb
Now we're adding Circular Marker to Heat Map, line of code would be like this,
full line of code at covid-map.ipynb
and the Final Heat Map which only showing total death, would be like this,
full line of code at covid-map.ipynb
End Line of Code
mariobgsp
newbie to programming worlds
November 2020