parameters: |
-
c : array_like
-
a scalar 2-d array. the values will be color-mapped.
-
x, y : array_like, optional
-
the coordinates of the quadrilateral corners. the quadrilateral for c[i,j] has corners at:
(x[i+1, j], y[i+1, j]) (x[i+1, j+1], y[i+1, j+1])
+--------+
| c[i,j] |
+--------+
(x[i, j], y[i, j]) (x[i, j+1], y[i, j+1]),
note that the column index corresponds to the x-coordinate, and the row index corresponds to y. for details, see the notes section below.
the dimensions of x and y should be one greater than those of c. alternatively, x, y and c may have equal dimensions, in which case the last row and column of c will be ignored.
if x and/or y are 1-d arrays or column vectors they will be expanded as needed into the appropriate 2-d arrays, making a rectangular grid.
-
cmap : str or
colormap , optional
-
a colormap instance or registered colormap name. the colormap maps the c values to colors. defaults to rcparams["image.cmap"] .
-
norm :
normalize , optional
-
the normalize instance scales the data values to the canonical colormap range [0, 1] for mapping to colors. by default, the data range is mapped to the colorbar range using linear scaling.
normalize实例将数据值缩放到用于映射到颜色的规范化colormap范围[0,1]。默认情况下,使用线性缩放将数据范围映射到colorbar范围。
-
vmin, vmax : scalar, optional, default: none
-
the colorbar range. if none, suitable min/max values are automatically chosen by the normalize instance (defaults to the respective min/max values of c in case of the default linear scaling).
-
edgecolors : {'none', none, 'face', color, color sequence}, optional
-
边缘颜色,默认none:
the singular form edgecolor works as an alias.
-
alpha : scalar, optional, default: none
-
透明度
-
shading : {'flat', 'gouraud'}, optional
-
the fill style, possible values:
填充式样
- 'flat': a solid color is used for each quad. the color of the quad (i, j), (i+1, j), (i, j+1), (i+1, j+1) is given by
c[i,j] .
- 'gouraud': each quad will be gouraud shaded: the color of the corners (i', j') are given by
c[i',j'] . the color values of the area in between is interpolated from the corner values. when gouraud shading is used, edgecolors is ignored.
-
snap : bool, optional, default: false
-
whether to snap the mesh to pixel boundaries.
|