xarray.Dataset.plot.quiver¶
-
Dataset.plot.
quiver
(x, y, ax, u, v, **kwargs)[source]¶ Quiver plot with Dataset variables.
- Parameters
ds (
Dataset
)x, y (
str
) – Variable names for x, y axis.u, v (
str
, optional) – Variable names for quiver or streamplot plots onlyhue (
str
, optional) – Variable by which to color scattered points or arrowshue_style (
str
, optional) – Can be either ‘discrete’ (legend) or ‘continuous’ (color bar).markersize (
str
, optional) – scatter only. Variable by which to vary size of scattered points.size_norm (optional) – Either None or ‘Norm’ instance to normalize the ‘markersize’ variable.
scale (scalar, optional) – Quiver only. Number of data units per arrow length unit. Use this to control the length of the arrows: larger values lead to smaller arrows
add_guide (
bool
, optional) –- Add a guide that depends on hue_style
for “discrete”, build a legend. This is the default for non-numeric hue variables.
for “continuous”, build a colorbar
row (
str
, optional) – If passed, make row faceted plots on this dimension namecol (
str
, optional) – If passed, make column faceted plots on this dimension namecol_wrap (
int
, optional) – Use together withcol
to wrap faceted plotsax (
matplotlib axes object
, optional) – If None, uses the current axis. Not applicable when using facets.subplot_kws (
dict
, optional) – Dictionary of keyword arguments for matplotlib subplots. Only applies to FacetGrid plotting.aspect (scalar, optional) – Aspect ratio of plot, so that
aspect * size
gives the width in inches. Only used if asize
is provided.size (scalar, optional) – If provided, create a new figure for the plot with the given size. Height (in inches) of each plot. See also:
aspect
.norm (
matplotlib.colors.Normalize
instance, optional) – If thenorm
has vmin or vmax specified, the corresponding kwarg must be None.vmin, vmax (
float
, optional) – Values to anchor the colormap, otherwise they are inferred from the data and other keyword arguments. When a diverging dataset is inferred, setting one of these values will fix the other by symmetry aroundcenter
. Setting both values prevents use of a diverging colormap. If discrete levels are provided as an explicit list, both of these values are ignored.cmap (
str
orcolormap
, optional) – The mapping from data values to color space. Either a matplotlib colormap name or object. If not provided, this will be eitherviridis
(if the function infers a sequential dataset) orRdBu_r
(if the function infers a diverging dataset). When Seaborn is installed,cmap
may also be a seaborn color palette. Ifcmap
is seaborn color palette,levels
must also be specified.colors (
color-like
orlist
ofcolor-like
, optional) – A single color or a list of colors. Thelevels
argument is required.center (
float
, optional) – The value at which to center the colormap. Passing this value implies use of a diverging colormap. Setting it toFalse
prevents use of a diverging colormap.robust (
bool
, optional) – If True andvmin
orvmax
are absent, the colormap range is computed with 2nd and 98th percentiles instead of the extreme values.extend (
{"neither", "both", "min", "max"}
, optional) – How to draw arrows extending the colorbar beyond its limits. If not provided, extend is inferred from vmin, vmax and the data limits.levels (
int
orlist-like object
, optional) – Split the colormap (cmap) into discrete color intervals. If an integer is provided, “nice” levels are chosen based on the data range: this can imply that the final number of levels is not exactly the expected one. Settingvmin
and/orvmax
withlevels=N
is equivalent to settinglevels=np.linspace(vmin, vmax, N)
.**kwargs (optional) – Additional keyword arguments to matplotlib