View source: R/nlm_randomcluster.R
nlm_randomcluster | R Documentation |
Simulates a random cluster nearest-neighbour neutral landscape.
nlm_randomcluster( ncol, nrow, resolution = 1, p, ai = c(0.5, 0.5), neighbourhood = 4, rescale = TRUE )
ncol |
[ |
nrow |
[ |
resolution |
[ |
p |
[ |
ai |
Vector with the cluster type distribution (percentages of occupancy). This directly controls the number of types via the given length. |
neighbourhood |
[ |
rescale |
[ |
This is a direct implementation of steps A - D of the modified random clusters algorithm by Saura & Martínez-Millán (2000), which creates naturalistic patchy patterns.
Raster with random values ranging from 0-1.
Saura, S. & Martínez-Millán, J. (2000) Landscape patterns simulation with a modified random clusters method. Landscape Ecology, 15, 661 – 678.
# simulate random clustering random_cluster <- nlm_randomcluster(ncol = 30, nrow = 30, p = 0.4, ai = c(0.25, 0.25, 0.5)) ## Not run: # visualize the NLM landscapetools::show_landscape(random_cluster) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.