我的图包含了1967-2018年的数据。这些盒子很难看。关于如何更改此图以使其更具可读性的任何提示?还是主要问题是试图显示的时间段太长?
ggplot(Cl) +
geom_boxplot(aes(x=CC_Date, y=CC_PWQMN,fill = Label,group = CC_Date),
width=0.5) +
xlab("") +
ylab("Cl(mg/l)") + #\n used for spacing between title and axis
scale_y_log10(breaks = c(0.1, 1, 10, 100, 1000),
limits = c(0.1, 1000), labels = c(0.1, 1, 10, 100, 1000)) +
scale_x_continuous(breaks = c(1967, 1975, 1983, 1991,1999,2008,2018),
limits = c(1967, 2019)) +
theme_bw() +
annotation_logticks(sides="l", size=1) +
theme(text=element_text(family="TNR", size=45)) +
theme(panel.grid.major = element_blank(), panel.grid.minor =
element_blank()) +
geom_hline(yintercept=120, colour="black", size=1) +
geom_hline(yintercept=50, linetype="longdash", colour="gray37", size=1) +
theme(axis.text.x = element_text(color="black"),axis.text.y =
element_text(color="black")) +
theme(panel.border = element_rect(colour="black", size = 1.3))+
theme(legend.position = "none")+
scale_fill_manual(values=c("gray70", "gray35"))