simulate_data: Simulate data

Description Usage Arguments Value See Also Examples

Description

Simulate spatially auto-correlated data using random fields.

Usage

1

Arguments

x

RasterLayer-class object to use as

n

integer number of species to simulate.

model

RP model object to use for simulating data.

transform

function to transform values output from the random fields simulation.

...

additional arguments passed to RFsimulate.

Value

RasterStack-class object with a layer for each species.

See Also

RFsimulate, simulate_cost, simulate_species.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 

# create raster
r <- raster(ncol=10, nrow=10, xmn=0, xmx=1, ymn=0, ymx=1)
values(r) <- 1

# simulate data using a Gaussian field
d <- simulate_data(r, n = 1, model = RandomFields::RMgauss())

# plot simulated data
plot(d, main = "random Gaussian field")


## End(Not run)

prioritizr/prioritizrutils documentation built on May 25, 2019, 12:20 p.m.