我试图面板标签的剧情添加到不同的方面。 我想他们是1:7,但是,下面的代码
d <- ggplot(diamonds, aes(carat, price, fill = ..density..)) +
xlim(0, 2) + stat_binhex(na.rm = TRUE) + opts(aspect.ratio = 1)
d1<-d + facet_wrap(~ color)
d1+annotate("text", x=0.25, y=1.5e+04, label=1:7)
产量
Error: When _setting_ aesthetics, they may only take one value. Problems: label
现在,我可以提供一个单一的价值和获取在所有方面复制。 但是,我怎么能已经在不同方面不同的标签使用注释()?