shift.ppp {spatstat} | R Documentation |
Applies a vector shift to a point pattern.
## S3 method for class 'ppp': shift(X, vec=c(0,0), ...)
X |
Point pattern (object of class "ppp" ). |
vec |
Vector of length 2 representing a translation. |
... |
Ignored |
The point pattern, and its window, are
translated by the vector vec
.
This is a method for the generic function shift
.
Another point pattern (of class "ppp"
) representing the
result of applying the vector shift.
Adrian Baddeley adrian@maths.uwa.edu.au http://www.maths.uwa.edu.au/~adrian/ and Rolf Turner rolf@math.unb.ca http://www.math.unb.ca/~rolf
shift
,
shift.owin
,
rotate
,
affine
data(cells) X <- shift(cells, c(2,3)) ## Not run: plot(X) # no discernible difference except coordinates are different ## End(Not run) plot(cells, pch=16) plot(shift(cells, c(0.03,0.03)), add=TRUE)