panel.Rd
panel functions for spplot functions, and functions that can be useful within these panel functions
spplot.key(sp.layout, rows = 1, cols = 1)
SpatialPolygonsRescale(obj, offset, scale = 1, fill = "black", col = "black",
plot.grid = TRUE, ...)
sp.lines(obj, col = 1, ...)
sp.points(obj, pch = 3, ...)
sp.polygons(obj, col = 1, fill = "transparent", ...)
sp.grid(obj, col = 1, alpha = 1,..., at = pretty(obj[[1]]), col.regions = col)
sp.text(loc, txt, ...)
sp.panel.layout(lst, p.number, ...)
bbexpand(x, fraction)
list; see spplot for definition
integer; panel row(s) for which the layout should be drawn
integer; panel column(s) for which the layout should be drawn
object of class SpatialPolygons-class for
SpatialPolygonsRescale
; of class SpatialLines-class,
Lines-class or Line-class for sp.lines
of a
class that has a coordinates-methods for sp.points
; of
class SpatialPolygons-class for sp.polygons
. When obj is
character, the actual object is retrieved by get(obj)
before its
class is evaluated.
offset for shifting a Polygons object
scale for rescaling
fill color
line color
logical; plot through grid functions (TRUE), or through traditional graphics functions (FALSE)
plotting character
numeric; values at which colour breaks should occur
colours to fill the grid cells, defaults to col
numeric vector of two elements
text to be plotted
alpha (transparency) level
sp.layout argument, see spplot
panel number; in a panel, panel.number() should be passed to this argument
length two numeric vector, containing a range
fraction to expand the range by
arguments passed to the underlying panel, lattice or grid functions
The panel functions of spplot, panel.gridplot
for grids,
panel.pointsplot
for points, or panel.polygonsplot
for lines
or polygons can be called with arguments (x,y,...)
.
Customizing spplot plots can be done by extending the panel function,
or by supplying an sp.layout argument; see the documentation for
spplot. Inside these panel functions, sp.panel.layout
is called to deal with plotting the items in a sp.layout
object.
SpatialPolygonsRescale
scales and shifts an object of class
SpatialPolygons-class; this is useful e.g. for scale bars, or other
layout items.
sp.lines
, sp.points
, sp.polygons
and sp.text
plot lines, points, polygons or text in a panel.
spplot.key
draws the sp.layout
object at given rows/cols.
sp.pagefn
can be passed as a page
argument, and will
call function spplot.key
for the last panel drawn on a page.
https://edzer.github.io/sp/ has a graph gallery with examples with R code.