Correction. It seems the problem isn't
(unit(0,"null")at all but rather with the change of object class from
"options" to whatever it is (maybe "theme).
This seems to solve the problem:
blankground <- function() {
theme(panel.background = element_blank(),
panel.grid.major = element_blank(),
panel.grid.minor = element_blank(),
panel.margin = unit(0,"null"),
plot.margin = rep(unit(0,"null"),4),
axis.ticks = element_blank(),
axis.text.x = element_blank(),
axis.text.y = element_blank(),
axis.title.x = element_blank(),
axis.title.y = element_blank(),
axis.ticks = element_blank()
)
}
Roey
On Saturday, September 15, 2012 8:47:30 PM UTC+2, Roey Angel wrote: