Change the position of the strip label in ggplot from the top to the bottom?

Viewed 80810

I know this is not quite a data visualization issue, but the boss asked for it, so I need to figure out if it is possible.

2 Answers

you can now use facet_wrap(~var, strip.position = "bottom"), though for some reason this results in the labels being located above the axis tick mark labels, rather than below (which I think would make more sense), as you can see from my screenshot of a small portion of my graph

screenshot of graph

If you want to have the label below, you have do to this

ggplot(zzz, aes(x = c1, y = c2)) +
  facet_wrap(~ gp, scales = "free", nrow = 3, strip.position = "bottom") +
  geom_point() +
  theme(
    aspect.ratio = 1,
    strip.background = element_blank(),
    strip.placement = "outside"
  )

As seen here: https://github.com/tidyverse/ggplot2/issues/2622

Related