参考:https://www.jb51.net/article/152685.htm

plt.text函数

import numpy as np
import matplotlib.mlab as mlab
import matplotlib.pyplot as plt
......
for x,y in zip(X,Y):
 plt.text(x, y+0.05, '%.0f' % y, ha='center', va= 'bottom',fontsize=11)
......
plt.show()

python matplotlib 绘图+显示数值

 

相关文章:

  • 2021-04-05
  • 2021-07-06
  • 2022-02-21
  • 2021-08-20
  • 2021-08-24
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-01-16
  • 2022-12-23
  • 2021-10-24
  • 2021-09-15
  • 2021-05-13
  • 2021-10-09
  • 2021-10-30
相关资源
相似解决方案