這個問題在這里已經有了答案:
或者,如果您根本不想旋轉,那么您可以手動構建每個條形。
ggplot(df)
geom_bar(aes(x = "Gene_A", y = Gene_A, colour = "Gene_A"), stat = "summary", fun = "mean", fill=c("black"), colour="black")
geom_bar(aes(x = "Gene_B", y = Gene_B, colour = "Gene_B"), stat = "summary", fun = "mean", fill=c("grey"), colour="black")
xlab("Gene")
ylab("Expression Level")
theme_classic()
輸出
![如何使用 ggplot2 在條形圖中繪制基因表達資料?[復制]](https://img.uj5u.com/2022/01/21/50f713ed4181426083220923abe61785.png)
轉載請註明出處,本文鏈接:https://www.uj5u.com/qiye/416775.html
標籤:
上一篇:在ggplot2中繪制日期間隔
下一篇:如何將一系列影像繪制到特定地圖上
