gpt4 book ai didi

r - ggplot 无法绘制最小点

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

我在使用 scale_size_area 绘制点时发现当数据跨越多个量级时,最小的点将被忽略。由于在某处四舍五入为零导致的可能错误?

require(ggplot2)
d = data.frame(x=1:4, y=rep(1,4), v=10^(1:4))

ggplot(d, aes(x, y, size=v)) + geom_point() +
geom_text(aes(label = v), size=2, col='red') +
scale_size_area(max_size = 50) +
theme(legend.position = "none")

enter image description here

最佳答案

这似乎是一个错误,因此我报告了它:https://github.com/hadley/ggplot2/issues/1022

关于r - ggplot 无法绘制最小点,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26402336/

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