First off and most importantly: thanks for this fantastic tool!
I'm collecting several issues (e.g. 355, 340) having to do with setting extents of geoviews elements.
Summary: This notebook demonstrates displaying regional gridded geospatial data in a HoloviewsHolomaps container. Through trial and error I have learned that I need to use different keywords to restrict the plotting region depending on whether I am using the Matplotlib or Bokeh backend to Holoviews. I do not see anything in the Holoviews or Geoviews documentation describing this behavior. I wonder if it is a bug; at the very least, the documentation probably should be more clear.
After creating a Holomap object with overlaid coastlines and political borders, I would expect the "padding" and "xlim"/"ylim" arguments to opts() to be usable from either backend. The below code demonstrates how they are not.
import os
import numpy as np
import xarray as xr
import geoviews as gv
import geoviews.feature as gf
import geoviews_tools as gt
gv.extension('matplotlib')
Same plot as above, now using bokeh. The plot shows up (below) centered at (0.0 E, 0.0 N). Zooming out with the mouse wheel reveals that the plot is there. South is now toward the top of the map.
Removing the latitude and longitude limits produces a correct plot using Bokeh, but without any surrounding context. Zooming out with the mouse wheel works.
First off and most importantly: thanks for this fantastic tool!
I'm collecting several issues (e.g. 355, 340) having to do with setting extents of geoviews elements.
Summary: This notebook demonstrates displaying regional gridded geospatial data in a Holoviews Holomaps container. Through trial and error I have learned that I need to use different keywords to restrict the plotting region depending on whether I am using the Matplotlib or Bokeh backend to Holoviews. I do not see anything in the Holoviews or Geoviews documentation describing this behavior. I wonder if it is a bug; at the very least, the documentation probably should be more clear.
After creating a Holomap object with overlaid coastlines and political borders, I would expect the "padding" and "xlim"/"ylim" arguments to opts() to be usable from either backend. The below code demonstrates how they are not.
Plot the data using GeoViews with matplotlib. The plot shows up (correctly) in the area surrounding Yatir Forest.
Same plot as above, now using bokeh. The plot shows up (below) centered at (0.0 E, 0.0 N). Zooming out with the mouse wheel reveals that the plot is there. South is now toward the top of the map.
Removing the latitude and longitude limits produces a correct plot using Bokeh, but without any surrounding context. Zooming out with the mouse wheel works.
bokeh allows use of the 'padding' argument to opts().
Setting padding has no discernible affect using matplotlib.
setting xlim and ylim using matplotlib achieves the same result as setting padding using Bokeh.