Last active
September 20, 2017 17:58
-
-
Save sergiolucero/983c6d92225dfaf4ef3eb7019c862ba7 to your computer and use it in GitHub Desktop.
de Chile a China
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 | |
import geopandas as gp | |
import requests | |
data = requests.get('http://sergiolucerovera.pythonanywhere.com/static/chile.shp') | |
chile = gp.GeoDataFrame(data.json()) | |
elihc = None # use geopandas.read_file?? | |
centroid = [(cc[1],cc[0]) for cc in chile.centroid] | |
cmap = folium(location=centroid, zoom=15, tiles='Staro_Pramen') | |
for rid, region in chile.iterrows: | |
folium.PolyLine(region.geometry).add_to(cmap) | |
cmap |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
http://www.bcn.cl/obtienearchivo?id=repositorio/10221/10398/1/division_regional.zip