File: mini_map.md

package info (click to toggle)
folium 0.20.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,168 kB
  • sloc: python: 4,489; makefile: 134; sh: 26
file content (52 lines) | stat: -rw-r--r-- 926 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
## MiniMap

```{code-cell} ipython3
import folium
from folium.plugins import MiniMap

m = folium.Map(location=(30, 20), zoom_start=4)

MiniMap().add_to(m)

m
```

### Make the minimap collapsible

```{code-cell} ipython3
m = folium.Map(location=(30, 20), zoom_start=4)
MiniMap(toggle_display=True).add_to(m)
m
```

### Change the minimap tile layer

```{code-cell} ipython3
m = folium.Map(location=(30, 20), zoom_start=4)
MiniMap(tile_layer="Cartodb dark_matter").add_to(m)
m
```

### Change the minimap position

```{code-cell} ipython3
m = folium.Map(location=(30, 20), zoom_start=4)
MiniMap(position="topleft").add_to(m)
m
```

### Change the minimap size

```{code-cell} ipython3
m = folium.Map(location=(30, 20), zoom_start=4)
MiniMap(width=400, height=100).add_to(m)
m
```

### Change the zoom offset

```{code-cell} ipython3
m = folium.Map(location=(30, 20), zoom_start=8)
MiniMap(zoom_level_offset=-8).add_to(m)
m
```