patchwork icon indicating copy to clipboard operation
patchwork copied to clipboard

plot_layout axes = "collect" not working with geom_sf

Open Maschette opened this issue 2 weeks ago • 0 comments

Hi, It seems that in both the cran and dev versions the axes = "collect" option in plot_layout() does not seem to be working. I also tried the "collect_x" option and it didnt work.

I do note the guide = "collect" is still working.

library(sf)
library(ggplot2)
library(patchwork)

nc <- sf::st_read(system.file("shape/nc.shp", package = "sf"), quiet = TRUE)
map <- ggplot(nc) +  geom_sf(aes(fill = AREA)) + xlab("sf plot")
map + map+plot_layout(ncol = 1, axes = "collect_x")

image

Maschette avatar Jun 25 '24 03:06 Maschette