Skip to content

Commit 569e282

Browse files
committed
this adds a bit of context about when to use which library
1 parent fed43ba commit 569e282

File tree

1 file changed

+22
-23
lines changed

1 file changed

+22
-23
lines changed

workshop/jupyter/content/notebooks/07-visualization.ipynb

Lines changed: 22 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@
88
"When it comes to visualizing geospatial data with/on maps with Python, a great number of tools and techniques\n",
99
"are available. In this lesson we will explore several of these:\n",
1010
"\n",
11-
"* [Folium](https://github.com/python-visualization/folium)\n",
12-
"* [ipyleaflet](https://ipyleaflet.readthedocs.io)\n",
13-
"* [Bokeh](https://bokeh.pydata.org)\n",
14-
"* [pydeck](https://pydeck.gl) - optional\n"
11+
"* [Folium](#Folium)\n",
12+
"* [ipyleaflet](#ipyleaflet)\n",
13+
"* [Bokeh](#Bokeh)\n",
14+
"* [pydeck](#pydeck)\n"
1515
]
1616
},
1717
{
@@ -21,9 +21,8 @@
2121
"## Folium\n",
2222
"Whenever you visit a website that has some kind of interactive map, it\n",
2323
"is quite probable that you are witnessing a map that has been made with\n",
24-
"a JavaScript library called [Leaflet](http://leafletjs.com). The\n",
25-
"other popular libraries you may encounter are\n",
26-
"[OpenLayers](https://openlayers.org) or [maplibre](https://maplibre.org/).\n",
24+
"a JavaScript library called [Leaflet](http://leafletjs.com). Other popular libraries you may encounter are\n",
25+
"[OpenLayers](https://openlayers.org) and [maplibre](https://maplibre.org/).\n",
2726
"\n",
2827
"The Python module \n",
2928
"[Folium](https://github.com/python-visualization/folium) makes\n",
@@ -167,7 +166,7 @@
167166
"source": [
168167
"### Folium and Streamlit\n",
169168
"Folium can also be [combined with Streamlit](https://folium.streamlit.app/). \n",
170-
"[Streamlit](https://streamlit.io) is a platform to create interactive web apps for your python data scripts.",
169+
"[Streamlit](https://streamlit.io) is a platform to create interactive web apps for your python data scripts.\n",
171170
"\n"
172171
]
173172
},
@@ -179,12 +178,10 @@
179178
}
180179
},
181180
"source": [
182-
"## Interactive maps in the Jupyter notebook with ipyleaflet\n",
183-
"ipyleaflet is a Jupyter/Leaflet bridge enabling interactive maps in the Jupyter notebook.\n",
184-
"(Although one can always save the results and use these maps in non-Jupyter contexts!).\n",
185-
"\n",
186-
"`ipyleaflet` is based on [ipywidgets](https://ipywidgets.readthedocs.io).\n",
187-
"ipywidgets are interactive HTML widgets for Jupyter notebooks and the IPython kernel.\n",
181+
"## ipyleaflet\n",
182+
"[ipyleaflet](https://ipyleaflet.readthedocs.io) provides similar functionality as folium, however because\n",
183+
"it is based on [ipywidgets](https://ipywidgets.readthedocs.io), it integrates with other components from\n",
184+
"the ipywidgets ecosystem (sliders, datagrids, tabs).\n",
188185
"\n",
189186
"Links:\n",
190187
"\n",
@@ -453,8 +450,10 @@
453450
"source": [
454451
"## Bokeh\n",
455452
"\n",
456-
"Bokeh is a very powerful framework to produce powerful maps in combination\n",
457-
"with data. With Geopandas and Bokeh one can produce nice looking interactive maps like in the image below:\n",
453+
"Bokeh is a powerful framework to produce tailored interactive map and data visualisations.\n",
454+
"Map features are limited compared to Folium, but there are more options to tailor the behaviour.\n",
455+
"Bokeh provides mechanisms to interact with a server side application. With Geopandas and Bokeh\n",
456+
"one can produce a nice looking interactive map like in the image below:\n",
458457
"\n",
459458
"![Bokeh and Geopandas Example](images/bokeh-example1.jpg)\n",
460459
"*Interactive Map with Bokeh and GeoPandas - Source: [CSC L6](https://automating-gis-processes.github.io/CSC/lessons/L6/interactive-map-bokeh.html)*\n"
@@ -895,16 +894,16 @@
895894
"cell_type": "markdown",
896895
"metadata": {},
897896
"source": [
898-
"## pydeck - OPTIONAL\n",
899-
"\n",
900-
"[pydeck](https://pydeck.gl/) is a WebGL2-powered, highly performant large-scale data visualization framework.\n",
901-
"We leave it you to explore pydeck through [its documentation](https://pydeck.gl/).\n",
897+
"## pydeck\n",
902898
"\n",
903-
"pydeck is part of [deck.gl](https://deck.gl/).\n",
899+
"Up till this point we've looked at 2D data visualisations. With [pydeck](https://pydeck.gl/)\n",
900+
"we switch to WebGL-powered data visualization, including 3D and vector tiles.\n",
901+
"pydeck is a python wrapper for the [deck.gl](https://deck.gl/) javascript library.\n",
902+
"deck.gl visualisations typically use a vector tile background (from [mapbox](https://mapbox.com), [maptiler](https://www.maptiler.com/), or similar)\n",
904903
"\n",
905-
"![From deck.gl repo Example](images/deck.gl.jpg)\n",
904+
"![Example by deck.gl](images/deck.gl.jpg)\n",
906905
"\n",
907-
"From their [GitHub README](https://github.com/visgl/deck.gl):\n",
906+
"From the [GitHub deck.gl README](https://github.com/visgl/deck.gl):\n",
908907
"\n",
909908
"*\"deck.gl is designed to simplify high-performance, WebGL-based visualization of large data sets.\n",
910909
"Users can quickly get impressive visual results with minimal effort by composing existing layers,\n",

0 commit comments

Comments
 (0)