📜  如何在 python 中标记散点图中的点 - TypeScript 代码示例

📅  最后修改于: 2022-03-11 14:48:16.153000             🧑  作者: Mango

代码示例1
y = [2.56422, 3.77284, 3.52623, 3.51468, 3.02199]
z = [0.15, 0.3, 0.45, 0.6, 0.75]
n = [58, 651, 393, 203, 123]

fig, ax = plt.scatter(z, y)

for i, txt in enumerate(n):
    ax.annotate(txt, (z[i], y[i]))