Created
June 15, 2022 03:27
-
-
Save amitrani6/3d3dd4058fcf9f9033622627e14bdb72 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
m = folium.Map(location=[48, -102], zoom_start=3) | |
folium.Choropleth( | |
geo_data=us_data_gdf, | |
name="choropleth", | |
data=us_data_gdf, | |
columns= ["GEOID","Total_Pop_2021"], | |
key_on="feature.properties.GEOID", | |
fill_color="YlGn", | |
fill_opacity=0.7, | |
line_opacity=0.2, | |
legend_name="Total Population By State, 2021").add_to(m) | |
folium.LayerControl().add_to(m) | |
# Display the Choropleth | |
m |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment