simulate_cost | R Documentation |
Generates simulated cost data using Gaussian random fields.
simulate_cost(x, n, intensity, sd, scale)
## S3 method for class 'Raster'
simulate_cost(x, n = 1, intensity = 100, sd = 20, scale = 2.5)
## S3 method for class 'SpatRaster'
simulate_cost(x, n = 1, intensity = 100, sd = 20, scale = 2.5)
x |
|
n |
|
intensity |
|
sd |
|
scale |
|
A terra::rast()
object with integer values greater than zero.
Other simulations:
simulate_data()
,
simulate_species()
## Not run:
# create raster
r <- terra::rast(
ncols = 10, nrows = 10, xmin = 0, xmax = 1, ymin = 0, ymax = 1, vals = 1
)
# simulate data
cost <- simulate_cost(r)
# plot simulated species
plot(cost, main = "simulated cost data", axes = FALSE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.