【发布时间】:2020-09-23 01:50:19
【问题描述】:
【问题讨论】:
标签: python pandas matplotlib plot graph
【问题讨论】:
标签: python pandas matplotlib plot graph
我觉得你需要matplotlib.pyplot.annotate:
import matplotlib.pyplot as plt
data = {'velocity': (1, 1), } # data points
fig, ax = plt.subplots()
ax.scatter(*zip(*data.values()))
ax.set_xlim(left=0, right=250) # x axis limits
ax.set_ylim(bottom=0, top=30) # y axis limits
ax.set_xlabel('μ*') # x axis label
ax.set_ylabel('β') # y axis label
for name, coordinates in data.items():
ax.annotate(name, coordinates)
【讨论】: