2
我想在r
的gridExtra
包中重新使用tableGrob
对象的主题/模板/默认值。如何在r中的gridExtra主题tableGrob对象
library(gridExtra)
tableGrob(df, cols = c("Custom Name", "Custom Name2"),
show.rownames = FALSE, h.even.alpha = 0)
tableGrob(df2, cols = c("Different Name", "Different Name2"),
show.rownames = FALSE, h.even.alpha = 0)
通知,我不想再重复show.rownames = FALSE
和h.even.alpha = 0
多次。创建某种类型的主题或模板的适当方法是什么,以避免在通过对tableGrob
的不同调用重复这些选项?我可以用类似于ggplot2
的主题来做到这一点,或者是我最好的选择吗?