相关疑难解决方法(0)

如何在ggplot中更改默认美学?

假设我更喜欢默认geom_point使用circle(pch=1)而不是solid dots(pch=16).您可以通过传递shape参数来更改标记的形状geom_point,例如

ggplot(diamonds, aes(depth, carat, colour=cut)) + geom_point(shape=1)
ggplot(diamonds, aes(depth, carat, colour=cut)) + geom_point(shape=16)
Run Code Online (Sandbox Code Playgroud)

但我无法弄清楚如何更改默认行为.

default r ggplot2 aesthetics

6
推荐指数
2
解决办法
2107
查看次数

标签 统计

aesthetics ×1

default ×1

ggplot2 ×1

r ×1