scatter_wrapper

scatter_wrapper(self, func, *args, s=None, size=None, markersize=None, c=None, color=None, markercolor=None, smin=None, smax=None, cmap=None, cmap_kw=None, norm=None, norm_kw=None, vmin=None, vmax=None, N=None, levels=None, values=None, symmetric=False, locator=None, locator_kw=None, lw=None, linewidth=None, linewidths=None, markeredgewidth=None, markeredgewidths=None, edgecolor=None, edgecolors=None, markeredgecolor=None, markeredgecolors=None, **kwargs)[source]

Adds keyword arguments to scatter that are more consistent with the plot keyword arguments and supports cmap_changer features.

Note

This function wraps scatter

Parameters
  • s, size, markersize (float or list of float, optional) – The marker size(s). The units are scaled by smin and smax.

  • smin, smax (float, optional) – The minimum and maximum marker size in units points ** 2 used to scale the s array. If not provided, the marker sizes are equivalent to the values in the s array.

  • c, color, markercolor (color-spec or list thereof, or array, optional) – The marker fill color(s). If this is an array of scalar values, the colors will be generated by passing the values through the norm normalizer and drawing from the cmap colormap.

  • cmap (colormap spec, optional) – The colormap specifer, passed to the Colormap constructor.

  • cmap_kw (dict-like, optional) – Passed to Colormap.

  • norm (normalizer spec, optional) – The colormap normalizer, used to warp data before passing it to DiscreteNorm. This is passed to the Norm constructor.

  • norm_kw (dict-like, optional) – Passed to Norm.

  • vmin, vmax (float, optional) – Used to determine level locations if levels is an integer. Actual levels may not fall exactly on vmin and vmax, but the minimum level will be no smaller than vmin and the maximum level will be no larger than vmax. If vmin or vmax is not provided, the minimum and maximum data values are used.

  • levels, N (int or list of float, optional) – The number of level edges, or a list of level edges. If the former, locator is used to generate this many levels at “nice” intervals. If the latter, the levels should be monotonically increasing or decreasing (note that decreasing levels will only work with pcolor plots, not contour plots). Default is rc[‘image.levels’] = 11. Note this means you can now discretize your colormap colors in a pcolor plot just like with contourf.

  • values (int or list of float, optional) – The number of level centers, or a list of level centers. If provided, levels are inferred using edges. This will override any levels input.

  • symmetric (bool, optional) – If True, automatically generated levels are symmetric about zero.

  • locator (locator-spec, optional) – The locator used to determine level locations if levels or values is an integer and vmin and vmax were not provided. Passed to the Locator constructor. Default is MaxNLocator with levels integer levels.

  • locator_kw (dict-like, optional) – Passed to Locator.

  • lw, linewidth, linewidths, markeredgewidth, markeredgewidths (float or list thereof, optional) – The marker edge width.

  • edgecolors, markeredgecolor, markeredgecolors (color-spec or list thereof, optional) – The marker edge color.

Other Parameters

**kwargs – Passed to scatter.