xoa.plot.plot_double_minimap

xoa.plot.plot_double_minimap#

xoa.plot.plot_double_minimap(obj, regional_ax='below', **kwargs)[source]#

Plot a global minimap and a regional minimap

It consists in two calls to plot_minimap() with the first one with a “global” extent. By default, the coordinates are plotted as single point on the global minimap, and the regional minimap is placed below the global one.

Parameters:
  • regional_ax (axes, list, str) – If a string, it should be one of "below", "above", "left" or "right" and it is interpreted as a relative position of the regional minimap with respect to the global one.

  • **kwargs – Parameters matching global_<param> are passed to the global minimap while parameters matching regional_<param> are passed to the regional minimap. All other parameters are passed to both minimaps, like parent, loc and size that place the global one as an inset of an axes.

Returns:

cartopy.mpl.geoaxes.GeoAxes, cartopy.mpl.geoaxes.GeoAxes – A tuple of (global_ax, regional_ax)

Example

In [1]: ds = xr.Dataset(coords={"lon": ("station", [-7, -5, -5]), "lat": ("station", [44, 44, 46])})

In [2]: plt.plot([0, 2], [0, 2])
Out[2]: [<matplotlib.lines.Line2D at 0x738bedebb380>]

In [3]: plot_double_minimap(ds)
Out[3]: (<GeoAxes: >, <GeoAxes: >)
../_images/api.plot.plot_double_minimap.png

See also

plot_minimap