【发布时间】:2015-06-10 22:53:14
【问题描述】:
我将使用 ggplot 从一个 4 列矩阵 pl1 绘制一个箱线图,每个方框上都有点。绘图说明如下:
p1 <- ggplot(pl1, aes(x=factor(Edge_n), y=get(make.names(y_label)), ymax=max(get(make.names(y_label)))*1.05))+
geom_boxplot(aes(fill=method), outlier.shape= NA)+
theme(text = element_text(size=20), aspect.ratio=1)+
xlab("Number of edges")+
ylab(y_label)+
scale_fill_manual(values=color_box)+
geom_point(aes(x=factor(Edge_n), y=get(make.names(true_des)), ymax=max(get(make.names(true_des)))*1.05, color=method),
position = position_dodge(width=0.75))+
scale_color_manual(values=color_pnt)
然后,我使用print(p1) 将其打印在打开的 pdf 上。但是,这对我不起作用,我收到以下错误:
Error in make.names(true_des) : object 'true_des' not found
有人可以帮忙吗?
【问题讨论】:
标签: r pdf ggplot2 printing boxplot