matplotlib.colors.
BoundaryNorm
(boundaries, ncolors, clip=False)¶Generate a colormap index based on discrete intervals.
Unlike Normalize
or LogNorm
,
BoundaryNorm
maps values to integers instead of to the
interval 01.
Mapping to the 01 interval could have been done via piecewise linear interpolation, but using integers seems simpler, and reduces the number of conversions back and forth between integer and floating point.
Parameters:  boundaries : arraylike
ncolors : int
clip : bool, optional


Notes
boundaries defines the edges of bins, and data falling within a bin is mapped to the color with the same index.
If the number of bins doesn’t equal ncolors, the color is chosen by linear interpolation of the bin number onto color numbers.
inverse
(value)¶Raises:  ValueError

