= plt.figure()
ax = fig.add_subplot(1,1,1)
ax.plot(randn(1000).cumsum())
#修改X轴的刻度
#刻度放在哪些位置
ticks =...Numbers", fontsize=24)
plt.xlabel("Value", fontsize=14)
plt.ylabel("Square of Value", fontsize=14)
# 设置刻度标记的大小...c , 并将其设置为要使用的颜色的名称,
plt.scatter(x_values, y_values, c='red', edgecolor='none', s=40)
(5).使用颜色映射
颜色映射...这些代码将 y值较小的点显示为浅蓝色, 并将 y 值较大的点显示为深蓝色....要让程序自动将图表保存到文件中, 可将对plt.show() 的调用替换为对plt.savefig() 的调用
plt.savefig('squares_plot.png', bbox_inches='