目录:
1、pandas官方画图链接
2、标记图中数据点
3、画图显示中文
4、画股票K线图
5、matplotlib基本用法
6、format输出
6、format输出例子
eps_range=[0.1,0.2,0.3] #plt.legend(['eps =%0.1f' % eps for eps in eps_range],loc='lower right') plt.legend(['eps ={:.1f}'.format(eps) for eps in eps_range],loc='lower right')
5、matplotlib基本用法
结论:python脚本文件中,matplotlib默认是阻塞模式,plt.plot(x) 或plt.imshow(x)是直接出图像,需要plt.show()后才能显示图像。不用ion()和ioff(),麻烦 !!!
plt.cla() #清除原有图像
1、pandas官方画图链接
http://pandas.pydata.org/pandas-docs/stable/visualization.html
http://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.plot.html?highlight=plot
http://pandas.pydata.org/pandas-docs/stable/generated/pandas.Series.plot.html?highlight=