用ggplot2跑图,提示要添加y,不然会被后面的替代:
Scale for y is already present.
Adding another scale for y, which will replace the existing scale.
p2 <-plot(res_psa, type = "ac", max_wtp = 100000, log_scale = FALSE) +
xlab("Willingness-to-pay threshold, × $1000/QALY")+
scale_y_continuous(name="Probability that the intervention is cost-effective",
limits=c(0, 1),
breaks=seq(0,1,0.1))+
#scale_color_manual(values = mycolors[1:2])+
scale_size_manual(values = c(3,3))+
theme_light()+
ggtitle("Cost-effectiveness Acceptability Curves")+
theme(
axis.text.x=element_text(),
strip.placement = "outside",
strip.background = element_rect(),
##图形标题设置 字体和大小
plot.title = element_text(family='Times', face='bold.italic',size = 22),
##x坐标轴
axis.title.x = element_text(family = 'Times',face = 'bold',size =15),
##y坐标轴
axis.title.y = element_text(family = 'Times',face = 'bold',size=10),
#图例标题
legend.title = element_text(family = 'Times',face = 'bold',size=10),
#图例内的字体
legend.text = element_text(family = 'Times',face = 'bold',size=12),
#图例位置
legend.position="bottom"
)
请问如何添加?