sequential colormaps:序列化(连续化)色图 colormap; gray:0-255 级灰度,0:黑色,1:白色,黑底白字; gray_r:翻转 gray 的显示,如果 gray 将图像显示为黑底白字,gray_r 会将其显示为白底黑字; diverging colormaps:两端发散的色图 colormaps; seismic qualitative colormaps:量化(离散化)色图; miscellaneous col...
_r, flag, flag_r, gist_earth, gist_earth_r, gist_gray, gist_gray_r, gist_heat, gist_heat_r, gist_ncar, gist_ncar_r, gist_rainbow, gist_rainbow_r, gist_stern, gist_stern_r, gist_yarg, gist_yarg_r, gnuplot, gnuplot2, gnuplot2_r, gnuplot_r, gray, gray_r, hot, hot_r, ...
gray, gray_r, hot, hot_r, hsv, hsv_r, icefire, icefire_r, inferno, inferno_r, jet, jet_r, magma, magma_r, mako, mako_r, nipy_spectral, nipy_spectral_r, ocean, ocean_r, pink, pink_r, plasma, plasma_r, prism, prism_r, rainbow, rainbow_r, rocket, rocket_r, seismic, sei...
'copper', 'copper_r', 'cubehelix', 'cubehelix_r', 'flag', 'flag_r','gist_earth', 'gist_earth_r', 'gist_gray', 'gist_gray_r', 'gist_heat','gist_heat_r', 'gist_ncar', 'gist_ncar_r', 'gist_rainbow', 'gist_rainbow_r','gist_stern', 'gist_stern_r', 'gist_yarg', 'g...
The cmap2gray function converts RGB values to grayscale values by forming a weighted sum of the R, G, and B components: 0.298936021293775 * R + 0.587043074451121 * G + 0.114020904255103 * B The coefficients used to calculate grayscale values in the cmap2gray function are identical to those...
GnBu、gray、cool、bwr、RdBu、tab20c 其中GnBu、RdBu、tab20c比较温和,cool、bwr视觉冲击性强。 引入外部cmap 由于matplotlib提供的颜色映射表是有限的,所以我们还需要借助外部的库包提供额外的颜色映射表。大气科学与海洋科学常用的两个外部颜色库包为Palettable与cmaps,这两个库包都可以使用conda命令安装。Palettable...
_r, cold_hot, cold_hot_r, cold_white_hot, cold_white_hot_r, cool, cool_r, coolwarm, coolwarm_r, copper, copper_r, cubehelix, cubehelix_r, cyan_copper, cyan_copper_r, cyan_orange, cyan_orange_r, flag, flag_r, gist_earth, gist_earth_r, gist_gray, gist_gray_r, gist_heat, ...
'copper', 'copper_r', 'cubehelix', 'cubehelix_r', 'flag', 'flag_r','gist_earth', 'gist_earth_r', 'gist_gray', 'gist_gray_r', 'gist_heat','gist_heat_r', 'gist_ncar', 'gist_ncar_r', 'gist_rainbow', 'gist_rainbow_r','gist_stern', 'gist_stern_r', ...
.gray() .hot() .register_cmap() .ScalarMappable() .autumn() .cool() .spectral() .viridis() .get_cmap() .Greys_r() .rainbow() .coolwarm() .Set1() .nipy_spectral() .jet_r() .winter() .hsv() .summer() .colors() Related Methods time.time() os...
换个颜色条参数, cmap 设置为afmhot_r: 实例 import matplotlib.pyplot as plt import numpy as np x = np.array([5,7,8,7,2,17,2,9,4,11,12,9,6]) y = np.array([99,86,87,88,111,86,103,87,94,78,77,85,86]) colors = np.array([0, 10, 20, 30, 40, 45, 50, 55, 60,...