图例:
1 theme(legend.title =element_blank()) 2 guides(fill = guide_legend(title = NULL)) # 去掉图例title 3 guides(fill = guide_legend(title = NULL,keywidth = 0.5,keyheight = 0.5)) #图例图标缩小 4 guides(fill=guide_legend(title = NULL,keywidth=0.6,keyheight=0.5,label.theme = element_text(size=5))) #缩小图例文字及图标 5 6 guides(fill=FALSE) # 去掉图例 7 theme(legend.position="none") # 去掉图例 8 scale_fill_discrete(guide=FALSE) # 去掉图例
分页:
1 facet_grid(class~.,scales = "free",space = "free") 2 facet_wrap(~class,scales = "free",nrow=2) 3 4 strip.background=element_blank() #分页背景去除