simExpCorrRF {AHMbook} | R Documentation |
Function creates Gaussian random field with negative exponential correlation and visualizes correlation and random field.
simExpCorrRF(variance = 1, theta = 1, size = 50, seed = NA, show.plots = TRUE)
variance |
variance of field. |
theta |
parameter governing spatial correlation (=1/phi) ("large theta means high correlation") Note that RMexp (which is used internally) is specified in terms of phi = 1/theta. |
size |
number of pixels along each side of the square site. |
seed |
used to generate reproducible output. |
show.plots |
if TRUE, the result will be displayed. |
A list with the values of the input arguments and the following additional elements:
field |
the random field variable, a vector of length size^2 |
grid |
the grid corresponding to field |
Marc Kéry & Andy Royle
Kéry, M. & Royle, J.A. (2021) Applied Hierarchical Modeling in Ecology AHM2 - 9.
# Run the function with default values and look at the output str(tmp <- simExpCorrRF())