Interactively explore data

9. Interactively explore data#

PolarToolkit provides some functions for interactively exploring gridded and point datasets with the use of the ipyleaflet python package. These are some necessary optional dependencies for the interactive functions, you’ll need to install these with:

pip install ipyleaflet ipywidgets ipython

or

mamba install ipyleaflet ipywidgets ipython
[1]:
import os

from polartoolkit import fetch, maps
[2]:
# set default to southern hemisphere for this notebook
os.environ["POLARTOOLKIT_HEMISPHERE"] = "south"
[3]:
# fetch bed topography data at 20km resolution
bedmap2_bed = fetch.bedmap2(layer="bed", spacing=20e3)

# fetch geothermal heat flux point measurements
GHF_point_data = fetch.ghf(version="burton-johnson-2020", points=True)
grdsample [WARNING]: Output sampling interval in x exceeds input interval and may lead to aliasing.
grdsample [WARNING]: Output sampling interval in y exceeds input interval and may lead to aliasing.
[4]:
maps.interactive_data(
    grid=bedmap2_bed,
    points=GHF_point_data[["x", "y", "GHF"]],
    points_z="GHF",
    coast=True,
)
[4]: