periodify(X, ...)
## S3 method for class 'ppp':
periodify(X, nx = 1, ny = 1, ...,
combine=TRUE, warn=TRUE, check=TRUE,
ix=(-nx):nx, iy=(-ny):ny,
ixy=expand.grid(ix=ix,iy=iy))
## S3 method for class 'psp':
periodify(X, nx = 1, ny = 1, ...,
combine=TRUE, warn=TRUE, check=TRUE,
ix=(-nx):nx, iy=(-ny):ny,
ixy=expand.grid(ix=ix,iy=iy))
## S3 method for class 'owin':
periodify(X, nx = 1, ny = 1, ...,
combine=TRUE, warn=TRUE,
ix=(-nx):nx, iy=(-ny):ny,
ixy=expand.grid(ix=ix,iy=iy))X in each direction.
(Overruled by ix, iy, ixy).X (if combine=TRUE) or
simply returned as a list of objects (combine=FALSE).X. (Overruled by ixy).X.combine=TRUE, an object of the same class as X.
If combine=FALSE, a list of objects of the same class as X.periodify is
generic, with methods for various kinds of spatial objects. The default is to make a 3 by 3 array of copies of X and
combine them into a single pattern of the same kind as X.
This can be used (for example) to compute toroidal or periodic
edge corrections for various operations on X.
If the arguments ix, iy or ixy are specified,
then these determine the grid positions of the copies of X
that will be made. For example (ix,iy) = (1, 2) means a
copy of X shifted by the vector (ix * w, iy * h) where
w,h are the width and height of the bounding rectangle of X.
If combine=TRUE (the default) the copies of X are
superimposed to create an object of the same kind as X.
If combine=FALSE the copies of X are returned as a list.
shiftdata(cells)
plot(periodify(cells))
a <- lapply(periodify(cells$window, combine=FALSE),
plot, add=TRUE,lty=2)Run the code above in your browser using DataLab