Teks legenda ggplot2
scale_color_manual(labels = c("black", "red"), values = c("lable1", "label2")) +
Yan Zhang
scale_color_manual(labels = c("black", "red"), values = c("lable1", "label2")) +
# Change the order of legend items
p + scale_x_discrete(limits=c("2", "0.5", "1"))
# Edit legend title and labels
p + scale_fill_discrete(name = "Dose", labels = c("A", "B", "C"))