Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
spatialthoughts committed Jul 2, 2024
1 parent 642ba98 commit 5c88dfa
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions code/python_dataviz/supplement_leafmap_osm.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@
"[Leafmap](https://leafmap.org/) comes with handy utilities to work with OpenStreetMap data. Using the popular package OSMNx in the background, it provides utility functions to download and visualize data from the OSM database.\n",
"\n",
"* [Leafmap OpenStreetMap Features](https://leafmap.org/notebooks/15_openstreetmap/)\n",
"* [`leafmap.osm` module](https://leafmap.org/osm/)"
"* [`leafmap.osm` module](https://leafmap.org/osm/)\n",
"\n",
"<img src='https://courses.spatialthoughts.com/images/python_dataviz/leafmap_osm.png' width=600/>\n"
]
},
{
Expand Down Expand Up @@ -48,11 +50,11 @@
},
"outputs": [],
"source": [
"import os\n",
"import geopandas as gpd\n",
"import folium\n",
"import geopandas as gpd\n",
"import leafmap.foliumap as leafmap\n",
"import osmnx"
"import os\n",
"import osmnx as ox"
]
},
{
Expand Down Expand Up @@ -247,11 +249,13 @@
"m = leafmap.Map(width=800, height=500)\n",
"m.add_basemap('CartoDB.DarkMatter')\n",
"m.add_osm_from_geocode('Bangalore', layer_name='Bangalore', info_mode=None)\n",
"\n",
"parking_zones.explore(\n",
" style_kwds={'fillOpacity': 0.3, 'weight': 0.5},\n",
" color='orange',\n",
" name='parking zones',\n",
" m=m)\n",
"\n",
"parking_locations.explore(\n",
" marker_type='circle',\n",
" marker_kwds={'radius': 1},\n",
Expand Down

0 comments on commit 5c88dfa

Please sign in to comment.