在学习中,经常会用到python进行画图,现在对一些常用的东西做一些记录
1、画图时设置
设置图例和字体大小
font1 = {'family': 'Times New Roman',
'weight': 'normal',
'size': 23,
}
legend = plt.legend(handles=[A, B], prop=font1)
设置label的size
plt.tick_params(labelsize=15)
2、保存
fig.savefig('示例.eps',dpi=600,format='eps')