I have a legend with lines and one box. I'm trying to get the box to line up with the lines. I have tried changing the first value in x.intersp=c(1, etc) to 0.5 and -0.5, but this seems to move the text and not the box. Any help would be appreciated.
Example code
x<-c(1,2,3,4)
y<-c(1,2,3,4)
plot(x,y)
mygray<-"gray"
#add legend
legend("bottomleft", legend = c("Survey Domain", "CA II Access Area","2020 SAMS Areas","EEZ"),
bg="white",cex=1,
bty="n",col=c(NA,"black","red","black"),
lty = c(NA,1,1,1),
fill=c(mygray,NA,NA,NA),
lwd=c(NA,2,2,1),border = c("black",NA,NA,NA),
seg.len=0.8,y.intersp=1,x.intersp=c(1,1,1,1))
