Created
March 4, 2021 20:46
-
-
Save jsta/42e70b448a97dfd663da76fda0a9f287 to your computer and use it in GitHub Desktop.
*Simple* example of plotting an xarray object with holoviews showing values on mouseover
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import holoviews as hv | |
import xarray as xr | |
hv.extension('bokeh') | |
test = xr.open_rasterio(raster_file) | |
gg = hv.Image(test, kdims = ['x', 'y']) | |
gg.opts(opts.Image(tools=['hover'])) | |
hv.save(gg, 'curve.html', backend='bokeh') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment