Preciso de sua ajuda e forneci os códigos de exemplo abaixo. Meu problema envolve colocar 'map2' em um quadrado no canto superior esquerdo de 'map1' e adicionar uma seta de 'map2' para um local específico em 'map1'. Pesquisei no site, mas os tópicos mais discutidos estão relacionados à fusão de duas camadas de dados.
Se você puder me ajudar, eu agradeceria muito.
library (tidyverse)
library (rnaturalearth)
world <- rnaturalearth::ne_countries(scale = "medium", returnclass = "sf")
map1<- ggplot(data = world) +
geom_sf() +
#annotation_scale(location = "bl", width_hint = 0.2) +
#annotation_north_arrow(location = "tr", which_north = "true",
# pad_x = unit(0.83, "in"), pad_y = unit(0.02, "in"),
# style = north_arrow_fancy_orienteering) +
coord_sf(xlim = c(35, 48), ylim=c(12, 22))+
xlab("Longtitude")+
ylab("Latitude")
map2<- ggplot(data = world) +
geom_sf() +
#annotation_scale(location = "bl", width_hint = 0.2) +
#annotation_north_arrow(location = "tr", which_north = "true",
# pad_x = unit(0.83, "in"), pad_y = unit(0.02, "in"),
# style = north_arrow_fancy_orienteering) +
coord_sf(xlim = c(5, 45), ylim=c(5, 45))+
xlab("Longtitude")+
ylab("Latitude")
map2