{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "data": { "text/html": [ "
Make this Notebook Trusted to load map: File -> Trust Notebook
" ], "text/plain": [ "" ] }, "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from folium import FeatureGroup, LayerControl, Map, Marker\n", "\n", "\n", "m = Map(location=[45.372, -121.6972], zoom_start=12, tiles=\"Stamen Terrain\")\n", "\n", "feature_group = FeatureGroup(name=\"Some icons\")\n", "Marker(location=[45.3288, -121.6625], popup=\"Mt. Hood Meadows\").add_to(feature_group)\n", "\n", "Marker(location=[45.3311, -121.7113], popup=\"Timberline Lodge\").add_to(feature_group)\n", "\n", "feature_group.add_to(m)\n", "LayerControl().add_to(m)\n", "\n", "m" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.0" } }, "nbformat": 4, "nbformat_minor": 1 }