easyclimate.plot.icon.plot_cell_triangular¶
- easyclimate.plot.icon.plot_cell_triangular(ds, da, *, ax=None, transform=None, lon_min=None, lon_max=None, lat_min=None, lat_max=None, auto_extent=True, extent_margin=0.05, cell_margin=0.05, global_plot=False, center_lon=None, input_radians=True, skip_large_lon_jump=True, max_polygon_lon_span=180.0, cmap=None, vmin=None, vmax=None, symmetric=False, percentile=98, edgecolor='none', linewidth=0.0, add_colorbar=True, cbar_kwargs=None, title=None, xlabel='Longitude', ylabel='Latitude', aspect='auto', lon_name_cell='clon', lat_name_cell='clat', lon_bnds_name='clon_bnds', lat_bnds_name='clat_bnds')¶
Plot ICON cell-centered scalar data on native triangular cells.
Parameters¶
- ds
xarray.Dataset ICON dataset containing cell centers and triangular cell bounds.
- da
xarray.DataArrayornumpy.ndarray Cell-centered scalar values on
ncells. Select time and vertical dimensions before calling, for exampleds["temp"].isel(time=0, plev=0).- ax
matplotlib.axes.Axes, optional Axes on which to draw. By default, use the current axes.
- transform
cartopy.crs.CRS, optional Coordinate reference system of the input coordinates for Cartopy axes.
- lon_min, lon_max, lat_min, lat_max
float, optional Plot extent in degrees. Cross-dateline longitude windows are supported.
- auto_extent
bool, default: True If True and no explicit extent is supplied, infer the extent from valid cell centers.
- extent_margin
float, default: 0.05 Fractional margin added to the automatically inferred extent.
- cell_margin
float, default: 0.05 Fractional padding used when selecting triangles near the visible extent.
- global_plot
bool, default: False If True, draw a global extent centered on
center_lon.- center_lon
float, optional Longitude center used for wrapping. If None, infer it from the extent or valid cell centers.
- input_radians
bool, default: True If True, ICON longitude and latitude variables are interpreted as radians and converted to degrees.
- skip_large_lon_jump
bool, default: True If True, skip triangles with very large wrapped longitude spans.
- max_polygon_lon_span
float, default: 180.0 Maximum accepted wrapped triangle longitude span in degrees.
- cmap
strormatplotlib.colors.Colormap, optional Colormap used for triangle values.
- vmin, vmax
float, optional Color limits. If omitted, infer them from selected values.
- symmetric
bool, default: False If True, infer symmetric color limits around zero.
- percentile
float, default: 98 Percentile used for automatic color-limit inference.
- edgecolor, linewidth
Polygon edge style passed to
matplotlib.collections.PolyCollection.- add_colorbar
bool, default: True If True, add a colorbar for the polygon collection.
- cbar_kwargs
dict, optional Keyword arguments passed to
Figure.colorbar.- title
str, optional Axes title. If None, use the data long name.
- xlabel, ylabel
str Axis labels used for plain Matplotlib axes.
- aspect
strorfloat, default: “auto” Aspect setting used for plain Matplotlib axes.
- lon_name_cell, lat_name_cell, lon_bnds_name, lat_bnds_name
str ICON coordinate and triangular-bound variable names.
Returns¶
matplotlib.collections.PolyCollectionPolygon collection added to the axes.
- ds