ggplot2: Making changes to symbols in the legend

流过昼夜 提交于 2019-11-30 23:23:13

Now that I'm sure it's what you want:

library(scales)
ggplot(data, aes(x = x, y = y)) +
          geom_point(aes(size = Rank, shape = Quantified)) +
          scale_shape_manual("Quantified", labels = c("Yes", "No"), values = c(1, 4)) + 
          guides(size = guide_legend(override.aes = list(shape = 1)))

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!