Created
May 5, 2016 18:06
-
-
Save DavidHickman/0e300d921d88ba61326a1241fde0ecf6 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
import folium | |
def simple_folium_map(lat, lng, description): | |
""" | |
Create a simple webmap with a green circle marker | |
Stamen map tile options = ['Stamen Toner', 'Stamen Terrain'] | |
""" | |
# Create webmap html | |
webmap = folium.Map(location=[lat, lng], tiles='Stamen Toner', zoom_start=16) | |
# Create circle marker over center green and add to the map | |
feature_marker = folium.CircleMarker([lat, lng], | |
radius=50, | |
popup=description, | |
color='#009933', | |
fill_color='#33cc33' | |
).add_to(webmap) | |
# Save the map to an output file | |
webmap.save("simple_folium_map.html") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment