gpt4 book ai didi

r - 向带状图添加标签?

转载 作者:行者123 更新时间:2023-12-04 06:08:08 25 4
gpt4 key购买 nike

stripchart :

x <- c(2, 8, 11, 19)
stripchart(x)



如何在点旁边添加标签 2、8、11、19?

最佳答案

使用 text并指定 y位置。带状图是用 y=1 绘制的,所以 text(x, y=1.1, ...)将在点上方绘制标签。

x <- c(2, 8, 11, 19)
stripchart(x)
text(x, 1.1, labels=x)

enter image description here

关于r - 向带状图添加标签?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8104733/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com