简体   繁体   中英

How can I hide the part of the legend using ggplot2?

我正在使用下面的代码生成一个情节,并希望隐藏“mag”(大小)图例,但仍保留“深度”(颜色)图例。

ggplot(quakes, aes(long, lat, size=mag, colour=depth)) + geom_point()

Try:

... + scale_size(guide="none") # As of Mar 2012

... + scale_size(legend = FALSE) # Deprecated

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM