Heterogeneity 如果你觉得将图形的各个成分分别定义,最后将他们合并起来更方便使用,你可以用下边这个形式:
title = ggtitle(paste("The distribution of", i, "under the impacts of the", m))
size = c(18, 18, 10, 10, 10, 18)
theme = theme(plot.title=element_text(size = size[i], hjust=0.5))
figtitle = list(title, theme)
graph = ggplot(...) + figtitle
ggplot
产生的是列表对象,所以可以将其组成成分放在列表里再加入该对象。