79701111

Date: 2025-07-14 15:59:22
Score: 0.5
Natty:
Report link

For option 2, you can simply add clip=FALSE to each instance of terra::plot():

r <- rast(system.file("ex/elev.tif", package="terra"))
mar1=c(2,1,1,1)
par(mfrow=c(2,2),mar=c(0,0,0,0),oma=c(0,0,1.5,0))
plot(r,legend=F,mar=mar1,ext=c(5.7,6.5,49.4,50.2),clip=FALSE)
mtext("Map one",adj=0)
plot(r,legend=F,mar=mar1,ext=c(6.1,6.5,49.4,50.2),clip=FALSE)
mtext("Map two",adj=0)
plot(r,legend=F,mar=mar1,ext=c(5.7,6.3,49.9,50),clip=FALSE)
mtext("Map three",adj=0)
plot(r,legend=F,mar=mar1,ext=c(5.7,6.5,49.4,50.2),clip=FALSE)
mtext("Map four",adj=0)

enter image description here

Reasons:
  • Probably link only (1):
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: AMBarbosa