When I use legend command in r, the size of the legend box is true, but when I zoom plot, the size of the legend box increases with a large scale. Are there any options to set height and width of legend box size such that when I zoom plot, legend box size changes with the same scale?
code:
par(mar=c(0,0,0,0))
legend("topright", legend = c("RPs", "APs", "Real position", "Estimation position"),
pch = c(4,17,21,21), col = c("black","green","blue", "red"), cex = 0.65,
pt.cex=1,text.font = 4)
I usewindows(x,y) before of plot command to resolve it. But I think it's not a good way. is there another way?