[英]R bokeh hexbin colorlegend?
I have been creating a hexagonal binning plot with rbokeh, which worked wonderfully. 我一直在用rbokeh创建一个六角形的装箱图,效果很好。 However, I would really like to a color legend into my plot, which does not seem to work.
但是,我真的很想在我的情节中加入一个颜色图例,但这似乎不起作用。
library(rbokeh)
figure(legend_location = "top_right") %>% ly_hexbin(x=hp,y=mpg,data=mtcars)
To clarify what I would like to achieve to have a similar legend as in ggplot2 with the geom_hex() command 为了澄清我希望通过使用geom_hex()命令获得与ggplot2类似的图例
library(ggplot2)
ggplot(data=mtcars, aes(x=hp,y=mpg)) + geom_hex()+theme_minimal()
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.