Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place. Commercial Alternative to JupyterHub.
Image: ubuntu2204
Installing ipyleaflet
Ensure you have ipyleaflet
installed. Since we cannot assume existing setups, here we provide the installation command:
Importing necessary libraries
Import the Map
and Marker
classes from ipyleaflet
:
Understanding ipyleaflet
ipyleaflet
is a Jupyter interactive widget library, providing an interactive map for data visualization in notebooks. It is built on top of leaflet.js
, a popular JavaScript library for mobile-friendly interactive maps.
Creating a map centered on California State University, Fresno
Initialize an interactive map. California State University, Fresno is located at latitude 36.8121 and longitude -119.7475:
Adding a marker
To mark the location of California State University, Fresno, create a Marker
and add it to the map:
Displaying the map
The final step is to display the map in a Jupyter notebook cell:
By running the cell containing the map object, you'll see the interactive map below:
This setup displays an interactive map centered on the location of California State University, Fresno with a marker indicating the campus location. The map allows you to pan and zoom, providing a hands-on exploration experience. Adjust the center
and zoom
for different locations and viewing preferences.