box function

draw a box

draw a box

Similar to box allowing adding a box around a map. This function will place the box around the mapped area.

add_box(...)

Arguments

  • ...: arguments passed to lines

See Also

add_legend, add_grid, add_mtext

Examples

v <- vect(system.file("ex/lux.shp", package="terra")) plot(v) add_box(col="red", lwd=3, xpd=TRUE)
  • Maintainer: Robert J. Hijmans
  • License: GPL (>= 3)
  • Last published: 2025-02-26