Annotating facet title as strip over facet
问题 I want to add a facet title as strip over a facetted plot in ggplot2 . My MWE throws an error. Any help will be highly appreciated. Thanks library(ggplot2) library(gtable) p <- ggplot(mtcars, aes(mpg, wt)) + geom_point() p <- p + facet_grid(. ~ cyl) # get gtable object Plot1 <- ggplot_gtable(ggplot_build(p)) # add label for top strip Plot1 <- gtable_add_rows(Plot1, Plot1$heights[[3]], 2) Plot1 <- gtable_add_grob(Plot1, list(rectGrob(gp = gpar(col = NA, fill = gray(0.5))), textGrob("Cyl", gp =