#设置颜色数组,指定颜色条带,添加颜色指示图例
ax3 = fig.add_subplot(212)
cf = ax3.scatter(x, y, s = sizes, c = y, cmap = 'jet...值为sizes数组
ax2 = fig.add_subplot(222, projection = '3d')
ax2.scatter(x, y, sizes, c = colors, cmap = 'jet...ax3 = fig.add_subplot(223, projection = '3d')
ax3.scatter(x, y, sizes, s = sizes, c = colors, cmap = 'jet...ax4 = ax[1, 1]
labels = ax4.contour(X, Y, Z(X, Y), 10, cmap = 'jet')
ax4.clabel(labels, inline = True...', alpha = .8)
#绘制等高线图,offset表示z值所处位置
labels = ax2.contour(X, Y, Z(X, Y), levels = 10, cmap = 'jet',