doc_content stringlengths 1 386k | doc_id stringlengths 5 188 |
|---|---|
get_edgecolor()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_edgecolor |
get_edgecolors()[source]
Alias for get_edgecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_edgecolors |
get_facecolor()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_facecolor |
get_facecolors()[source]
Alias for get_facecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_facecolors |
get_fc()[source]
Alias for get_facecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_fc |
get_figure()[source]
Return the Figure instance the artist belongs to. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_figure |
get_fill()[source]
Return whether face is colored. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_fill |
get_gid()[source]
Return the group id. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_gid |
get_hatch()[source]
Return the current hatching pattern. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_hatch |
get_in_layout()[source]
Return boolean flag, True if artist is included in layout calculations. E.g. Constrained Layout Guide, Figure.tight_layout(), and fig.savefig(fname, bbox_inches='tight'). | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_in_layout |
get_joinstyle()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_joinstyle |
get_label()[source]
Return the label used for this artist in the legend. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_label |
get_linestyle()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_linestyle |
get_linestyles()[source]
Alias for get_linestyle. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_linestyles |
get_linewidth()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_linewidth |
get_linewidths()[source]
Alias for get_linewidth. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_linewidths |
get_ls()[source]
Alias for get_linestyle. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_ls |
get_lw()[source]
Alias for get_linewidth. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_lw |
get_offset_transform()[source]
Return the Transform instance used by this artist offset. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_offset_transform |
get_offsets()[source]
Return the offsets for the collection. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_offsets |
get_path_effects()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_path_effects |
get_paths()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_paths |
get_picker()[source]
Return the picking behavior of the artist. The possible values are described in set_picker. See also
set_picker, pickable, pick | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_picker |
get_pickradius()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_pickradius |
get_rasterized()[source]
Return whether the artist is to be rasterized. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_rasterized |
get_sizes()[source]
Return the sizes ('areas') of the elements in the collection. Returns
array
The 'area' of each element. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_sizes |
get_sketch_params()[source]
Return the sketch parameters for the artist. Returns
tuple or None
A 3-tuple with the following elements:
scale: The amplitude of the wiggle perpendicular to the source line.
length: The length of the wiggle along the line.
randomness: The scale factor by which the length is shrunken or expanded. Returns None if no sketch parameters were set. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_sketch_params |
get_snap()[source]
Return the snap setting. See set_snap for details. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_snap |
get_tightbbox(renderer)[source]
Like Artist.get_window_extent, but includes any clipping. Parameters
rendererRendererBase subclass
renderer that will be used to draw the figures (i.e. fig.canvas.get_renderer()) Returns
Bbox
The enclosing bounding box (in figure pixel coordinates). | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_tightbbox |
get_transform()[source]
Return the Transform instance used by this artist. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_transform |
get_transformed_clip_path_and_affine()[source]
Return the clip path with the non-affine part of its transformation applied, and the remaining affine part of its transformation. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_transformed_clip_path_and_affine |
get_transforms()[source] | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_transforms |
get_url()[source]
Return the url. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_url |
get_urls()[source]
Return a list of URLs, one for each element of the collection. The list contains None for elements without a URL. See Hyperlinks for an example. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_urls |
get_visible()[source]
Return the visibility. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_visible |
get_window_extent(renderer)[source]
Get the artist's bounding box in display space. The bounding box' width and height are nonnegative. Subclasses should override for inclusion in the bounding box "tight" calculation. Default is to return an empty bounding box at 0, 0. Be careful when using this function, the results will not update if the artist window extent of the artist changes. The extent can change due to any changes in the transform stack, such as changing the axes limits, the figure size, or the canvas used (as is done when saving a figure). This can lead to unexpected behavior where interactive figures will look fine on the screen, but will save incorrectly. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_window_extent |
get_zorder()[source]
Return the artist's zorder. | matplotlib.collections_api#matplotlib.collections.PolyCollection.get_zorder |
have_units()[source]
Return whether units are set on any axis. | matplotlib.collections_api#matplotlib.collections.PolyCollection.have_units |
is_transform_set()[source]
Return whether the Artist has an explicitly set transform. This is True after set_transform has been called. | matplotlib.collections_api#matplotlib.collections.PolyCollection.is_transform_set |
pchanged()[source]
Call all of the registered callbacks. This function is triggered internally when a property is changed. See also add_callback
remove_callback | matplotlib.collections_api#matplotlib.collections.PolyCollection.pchanged |
pick(mouseevent)[source]
Process a pick event. Each child artist will fire a pick event if mouseevent is over the artist and the artist has picker set. See also
set_picker, get_picker, pickable | matplotlib.collections_api#matplotlib.collections.PolyCollection.pick |
pickable()[source]
Return whether the artist is pickable. See also
set_picker, get_picker, pick | matplotlib.collections_api#matplotlib.collections.PolyCollection.pickable |
properties()[source]
Return a dictionary of all the properties of the artist. | matplotlib.collections_api#matplotlib.collections.PolyCollection.properties |
remove()[source]
Remove the artist from the figure if possible. The effect will not be visible until the figure is redrawn, e.g., with FigureCanvasBase.draw_idle. Call relim to update the axes limits if desired. Note: relim will not see collections even if the collection was added to the axes with autolim = True. Note: there is no support for removing the artist's legend entry. | matplotlib.collections_api#matplotlib.collections.PolyCollection.remove |
remove_callback(oid)[source]
Remove a callback based on its observer id. See also add_callback | matplotlib.collections_api#matplotlib.collections.PolyCollection.remove_callback |
set(*, agg_filter=<UNSET>, alpha=<UNSET>, animated=<UNSET>, antialiased=<UNSET>, array=<UNSET>, capstyle=<UNSET>, clim=<UNSET>, clip_box=<UNSET>, clip_on=<UNSET>, clip_path=<UNSET>, cmap=<UNSET>, color=<UNSET>, edgecolor=<UNSET>, facecolor=<UNSET>, gid=<UNSET>, hatch=<UNSET>, in_layout=<UNSET>, joinstyle=<UNSET>, label=<UNSET>, linestyle=<UNSET>, linewidth=<UNSET>, norm=<UNSET>, offset_transform=<UNSET>, offsets=<UNSET>, path_effects=<UNSET>, paths=<UNSET>, picker=<UNSET>, pickradius=<UNSET>, rasterized=<UNSET>, sizes=<UNSET>, sketch_params=<UNSET>, snap=<UNSET>, transform=<UNSET>, url=<UNSET>, urls=<UNSET>, verts=<UNSET>, verts_and_codes=<UNSET>, visible=<UNSET>, zorder=<UNSET>)[source]
Set multiple properties at once. Supported properties are
Property Description
agg_filter a filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array
alpha array-like or scalar or None
animated bool
antialiased or aa or antialiaseds bool or list of bools
array array-like or None
capstyle CapStyle or {'butt', 'projecting', 'round'}
clim (vmin: float, vmax: float)
clip_box Bbox
clip_on bool
clip_path Patch or (Path, Transform) or None
cmap Colormap or str or None
color color or list of rgba tuples
edgecolor or ec or edgecolors color or list of colors or 'face'
facecolor or facecolors or fc color or list of colors
figure Figure
gid str
hatch {'/', '\', '|', '-', '+', 'x', 'o', 'O', '.', '*'}
in_layout bool
joinstyle JoinStyle or {'miter', 'round', 'bevel'}
label object
linestyle or dashes or linestyles or ls str or tuple or list thereof
linewidth or linewidths or lw float or list of floats
norm Normalize or None
offset_transform Transform
offsets (N, 2) or (2,) array-like
path_effects AbstractPathEffect
paths list of array-like
picker None or bool or float or callable
pickradius float
rasterized bool
sizes ndarray or None
sketch_params (scale: float, length: float, randomness: float)
snap bool or None
transform Transform
url str
urls list of str or None
verts list of array-like
verts_and_codes unknown
visible bool
zorder float | matplotlib.collections_api#matplotlib.collections.PolyCollection.set |
set_aa(aa)[source]
Alias for set_antialiased. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_aa |
set_agg_filter(filter_func)[source]
Set the agg filter. Parameters
filter_funccallable
A filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_agg_filter |
set_alpha(alpha)[source]
Set the alpha value used for blending - not supported on all backends. Parameters
alphaarray-like or scalar or None
All values must be within the 0-1 range, inclusive. Masked values and nans are not supported. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_alpha |
set_animated(b)[source]
Set whether the artist is intended to be used in an animation. If True, the artist is excluded from regular drawing of the figure. You have to call Figure.draw_artist / Axes.draw_artist explicitly on the artist. This appoach is used to speed up animations using blitting. See also matplotlib.animation and Faster rendering by using blitting. Parameters
bbool | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_animated |
set_antialiased(aa)[source]
Set the antialiasing state for rendering. Parameters
aabool or list of bools | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_antialiased |
set_antialiaseds(aa)[source]
Alias for set_antialiased. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_antialiaseds |
set_array(A)[source]
Set the value array from array-like A. Parameters
Aarray-like or None
The values that are mapped to colors. The base class ScalarMappable does not make any assumptions on the dimensionality and shape of the value array A. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_array |
set_capstyle(cs)[source]
Set the CapStyle for the collection (for all its elements). Parameters
csCapStyle or {'butt', 'projecting', 'round'} | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_capstyle |
set_clim(vmin=None, vmax=None)[source]
Set the norm limits for image scaling. Parameters
vmin, vmaxfloat
The limits. The limits may also be passed as a tuple (vmin, vmax) as a single positional argument. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_clim |
set_clip_box(clipbox)[source]
Set the artist's clip Bbox. Parameters
clipboxBbox | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_clip_box |
set_clip_on(b)[source]
Set whether the artist uses clipping. When False artists will be visible outside of the axes which can lead to unexpected results. Parameters
bbool | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_clip_on |
set_clip_path(path, transform=None)[source]
Set the artist's clip path. Parameters
pathPatch or Path or TransformedPath or None
The clip path. If given a Path, transform must be provided as well. If None, a previously set clip path is removed.
transformTransform, optional
Only used if path is a Path, in which case the given Path is converted to a TransformedPath using transform. Notes For efficiency, if path is a Rectangle this method will set the clipping box to the corresponding rectangle and set the clipping path to None. For technical reasons (support of set), a tuple (path, transform) is also accepted as a single positional parameter. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_clip_path |
set_cmap(cmap)[source]
Set the colormap for luminance data. Parameters
cmapColormap or str or None | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_cmap |
set_color(c)[source]
Set both the edgecolor and the facecolor. Parameters
ccolor or list of rgba tuples
See also
Collection.set_facecolor, Collection.set_edgecolor
For setting the edge or face color individually. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_color |
set_dashes(ls)[source]
Alias for set_linestyle. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_dashes |
set_ec(c)[source]
Alias for set_edgecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_ec |
set_edgecolor(c)[source]
Set the edgecolor(s) of the collection. Parameters
ccolor or list of colors or 'face'
The collection edgecolor(s). If a sequence, the patches cycle through it. If 'face', match the facecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_edgecolor |
set_edgecolors(c)[source]
Alias for set_edgecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_edgecolors |
set_facecolor(c)[source]
Set the facecolor(s) of the collection. c can be a color (all patches have same color), or a sequence of colors; if it is a sequence the patches will cycle through the sequence. If c is 'none', the patch will not be filled. Parameters
ccolor or list of colors | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_facecolor |
set_facecolors(c)[source]
Alias for set_facecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_facecolors |
set_fc(c)[source]
Alias for set_facecolor. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_fc |
set_figure(fig)[source]
Set the Figure instance the artist belongs to. Parameters
figFigure | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_figure |
set_gid(gid)[source]
Set the (group) id for the artist. Parameters
gidstr | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_gid |
set_hatch(hatch)[source]
Set the hatching pattern hatch can be one of: / - diagonal hatching
\ - back diagonal
| - vertical
- - horizontal
+ - crossed
x - crossed diagonal
o - small circle
O - large circle
. - dots
* - stars
Letters can be combined, in which case all the specified hatchings are done. If same letter repeats, it increases the density of hatching of that pattern. Hatching is supported in the PostScript, PDF, SVG and Agg backends only. Unlike other properties such as linewidth and colors, hatching can only be specified for the collection as a whole, not separately for each member. Parameters
hatch{'/', '\', '|', '-', '+', 'x', 'o', 'O', '.', '*'} | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_hatch |
set_in_layout(in_layout)[source]
Set if artist is to be included in layout calculations, E.g. Constrained Layout Guide, Figure.tight_layout(), and fig.savefig(fname, bbox_inches='tight'). Parameters
in_layoutbool | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_in_layout |
set_joinstyle(js)[source]
Set the JoinStyle for the collection (for all its elements). Parameters
jsJoinStyle or {'miter', 'round', 'bevel'} | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_joinstyle |
set_label(s)[source]
Set a label that will be displayed in the legend. Parameters
sobject
s will be converted to a string by calling str. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_label |
set_linestyle(ls)[source]
Set the linestyle(s) for the collection.
linestyle description
'-' or 'solid' solid line
'--' or 'dashed' dashed line
'-.' or 'dashdot' dash-dotted line
':' or 'dotted' dotted line Alternatively a dash tuple of the following form can be provided: (offset, onoffseq),
where onoffseq is an even length tuple of on and off ink in points. Parameters
lsstr or tuple or list thereof
Valid values for individual linestyles include {'-', '--', '-.', ':', '', (offset, on-off-seq)}. See Line2D.set_linestyle for a complete description. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_linestyle |
set_linestyles(ls)[source]
Alias for set_linestyle. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_linestyles |
set_linewidth(lw)[source]
Set the linewidth(s) for the collection. lw can be a scalar or a sequence; if it is a sequence the patches will cycle through the sequence Parameters
lwfloat or list of floats | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_linewidth |
set_linewidths(lw)[source]
Alias for set_linewidth. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_linewidths |
set_ls(ls)[source]
Alias for set_linestyle. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_ls |
set_lw(lw)[source]
Alias for set_linewidth. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_lw |
set_norm(norm)[source]
Set the normalization instance. Parameters
normNormalize or None
Notes If there are any colorbars using the mappable for this norm, setting the norm of the mappable will reset the norm, locator, and formatters on the colorbar to default. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_norm |
set_offset_transform(transOffset)[source]
Set the artist offset transform. Parameters
transOffsetTransform | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_offset_transform |
set_offsets(offsets)[source]
Set the offsets for the collection. Parameters
offsets(N, 2) or (2,) array-like | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_offsets |
set_path_effects(path_effects)[source]
Set the path effects. Parameters
path_effectsAbstractPathEffect | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_path_effects |
set_paths(verts, closed=True)[source]
Set the vertices of the polygons. Parameters
vertslist of array-like
The sequence of polygons [verts0, verts1, ...] where each element verts_i defines the vertices of polygon i as a 2D array-like of shape (M, 2).
closedbool, default: True
Whether the polygon should be closed by adding a CLOSEPOLY connection at the end. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_paths |
set_picker(picker)[source]
Define the picking behavior of the artist. Parameters
pickerNone or bool or float or callable
This can be one of the following:
None: Picking is disabled for this artist (default). A boolean: If True then picking will be enabled and the artist will fire a pick event if the mouse event is over the artist. A float: If picker is a number it is interpreted as an epsilon tolerance in points and the artist will fire off an event if its data is within epsilon of the mouse event. For some artists like lines and patch collections, the artist may provide additional data to the pick event that is generated, e.g., the indices of the data within epsilon of the pick event
A function: If picker is callable, it is a user supplied function which determines whether the artist is hit by the mouse event: hit, props = picker(artist, mouseevent)
to determine the hit test. if the mouse event is over the artist, return hit=True and props is a dictionary of properties you want added to the PickEvent attributes. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_picker |
set_pickradius(pr)[source]
Set the pick radius used for containment tests. Parameters
prfloat
Pick radius, in points. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_pickradius |
set_rasterized(rasterized)[source]
Force rasterized (bitmap) drawing for vector graphics output. Rasterized drawing is not supported by all artists. If you try to enable this on an artist that does not support it, the command has no effect and a warning will be issued. This setting is ignored for pixel-based output. See also Rasterization for vector graphics. Parameters
rasterizedbool | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_rasterized |
set_sizes(sizes, dpi=72.0)[source]
Set the sizes of each member of the collection. Parameters
sizesndarray or None
The size to set for each element of the collection. The value is the 'area' of the element.
dpifloat, default: 72
The dpi of the canvas. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_sizes |
set_sketch_params(scale=None, length=None, randomness=None)[source]
Set the sketch parameters. Parameters
scalefloat, optional
The amplitude of the wiggle perpendicular to the source line, in pixels. If scale is None, or not provided, no sketch filter will be provided.
lengthfloat, optional
The length of the wiggle along the line, in pixels (default 128.0)
randomnessfloat, optional
The scale factor by which the length is shrunken or expanded (default 16.0) The PGF backend uses this argument as an RNG seed and not as described above. Using the same seed yields the same random shape. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_sketch_params |
set_snap(snap)[source]
Set the snapping behavior. Snapping aligns positions with the pixel grid, which results in clearer images. For example, if a black line of 1px width was defined at a position in between two pixels, the resulting image would contain the interpolated value of that line in the pixel grid, which would be a grey value on both adjacent pixel positions. In contrast, snapping will move the line to the nearest integer pixel value, so that the resulting image will really contain a 1px wide black line. Snapping is currently only supported by the Agg and MacOSX backends. Parameters
snapbool or None
Possible values:
True: Snap vertices to the nearest pixel center.
False: Do not modify vertex positions.
None: (auto) If the path contains only rectilinear line segments, round to the nearest pixel center. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_snap |
set_transform(t)[source]
Set the artist transform. Parameters
tTransform | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_transform |
set_url(url)[source]
Set the url for the artist. Parameters
urlstr | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_url |
set_urls(urls)[source]
Parameters
urlslist of str or None
Notes URLs are currently only implemented by the SVG backend. They are ignored by all other backends. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_urls |
set_verts(verts, closed=True)[source]
Set the vertices of the polygons. Parameters
vertslist of array-like
The sequence of polygons [verts0, verts1, ...] where each element verts_i defines the vertices of polygon i as a 2D array-like of shape (M, 2).
closedbool, default: True
Whether the polygon should be closed by adding a CLOSEPOLY connection at the end. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_verts |
set_verts_and_codes(verts, codes)[source]
Initialize vertices with path codes. | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_verts_and_codes |
set_visible(b)[source]
Set the artist's visibility. Parameters
bbool | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_visible |
set_zorder(level)[source]
Set the zorder for the artist. Artists with lower zorder values are drawn first. Parameters
levelfloat | matplotlib.collections_api#matplotlib.collections.PolyCollection.set_zorder |
to_rgba(x, alpha=None, bytes=False, norm=True)[source]
Return a normalized rgba array corresponding to x. In the normal case, x is a 1D or 2D sequence of scalars, and the corresponding ndarray of rgba values will be returned, based on the norm and colormap set for this ScalarMappable. There is one special case, for handling images that are already rgb or rgba, such as might have been read from an image file. If x is an ndarray with 3 dimensions, and the last dimension is either 3 or 4, then it will be treated as an rgb or rgba array, and no mapping will be done. The array can be uint8, or it can be floating point with values in the 0-1 range; otherwise a ValueError will be raised. If it is a masked array, the mask will be ignored. If the last dimension is 3, the alpha kwarg (defaulting to 1) will be used to fill in the transparency. If the last dimension is 4, the alpha kwarg is ignored; it does not replace the pre-existing alpha. A ValueError will be raised if the third dimension is other than 3 or 4. In either case, if bytes is False (default), the rgba array will be floats in the 0-1 range; if it is True, the returned rgba array will be uint8 in the 0 to 255 range. If norm is False, no normalization of the input data is performed, and it is assumed to be in the range (0-1). | matplotlib.collections_api#matplotlib.collections.PolyCollection.to_rgba |
update(props)[source]
Update this artist's properties from the dict props. Parameters
propsdict | matplotlib.collections_api#matplotlib.collections.PolyCollection.update |
update_from(other)[source]
Copy properties from other to self. | matplotlib.collections_api#matplotlib.collections.PolyCollection.update_from |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.