背景色为白色
p+ theme_set(theme_bw())
去掉网格线
p+theme(panel.grid.major=element_line(colour=NA))
或者:
p+theme_bw()+theme(panel.grid=element_blank(),panel.border=element_blank(),axis.line=element_line(size=1,colour=”black”))
尊重他人劳动成果,转载请注明出处:Bluesky's blog » ggplot2画图怎么去掉背景淡灰底色和网格线?