【发布时间】:2021-06-24 10:03:33
【问题描述】:
我试图在我的论文中包含一些情节,但比例尺的字体太小。有没有办法让它看起来更大?
这是我的代码
library(ggbeeswarm)
library(ggpubr)
library(ggplot2)
ggplot(data = wccplots_long, aes(x = wcc.group, y = Value)) +
geom_boxplot() +
geom_quasirandom(aes(colour = as.factor(X28_day_mortality) , shape = sex, fill = as.factor(X28_day_mortality)), width = 0.4) +
theme(axis.text.x = element_text(angle = 45, hjust = 1 )) +
labs(x = "WCC Group", y = "Protein level in plasma", title = "Top 5 downregulated Proteins", fill = "Mortality", shape = "Sex", colour = "Mortality",cex.lab=3, cex.axis=3, cex.main=3, cex.sub=3 ) + stat_compare_means(method = "t.test", comparisons = list(c("Low", "Medium"), c("Low", "High"), c("Medium", "High") ), aes(label = ..p.signif..)) +
scale_colour_manual(values =c("red", "black")) +
scale_fill_manual(values =c("red", "black")) +
scale_shape_manual(values =c(24,22)) + facet_wrap(~Protein, ncol = 5, scales = "free_y", labeller = labeller(Protein = proteinnames)) +
theme(strip.background = element_rect(fill="skyblue1", size=2, color="black")) +
theme(strip.text = element_text(size = 14, face = "bold"), aspect.ratio = 1) +
scale_y_continuous(expand = expansion(mult = c(0.05,0.15) ))
【问题讨论】:
-
如果您创建一个小的可重现示例以及预期的输出,这将更容易提供帮助。阅读how to give a reproducible example。
标签: r plot size scale scatter-plot