Xarray Image#

Download this notebook from GitHub (right-click to download).


import geoviews as gv
import geoviews.feature as gf
import xarray as xr
from cartopy import crs

gv.extension('matplotlib')

Define data#

ensemble = xr.open_dataset('../../data/ensemble.nc')
dataset = gv.Dataset(ensemble, ['longitude', 'latitude', 'time'], 'surface_temperature', crs=crs.PlateCarree())
images = dataset.to(gv.Image)
# Equivalent full definition:
# images = dataset.to(gv.Image, ['longitude', 'latitude'], 'surface_temperature', 'time')

Plot#

images.opts(cmap='viridis', colorbar=True, fig_size=250) * gf.coastline
This web page was generated from a Jupyter notebook and not all interactivity will work on this website. Right click to download and run locally for full Python-backed interactivity.

Download this notebook from GitHub (right-click to download).