translate_raster: translate_raster

Description Usage Arguments Details Value References See Also Examples

View source: R/translate_raster.R

Description

Torus translation

Usage

1
2
3
4
5
6
7
8
translate_raster(
  raster,
  steps_x = NULL,
  steps_y = NULL,
  return_input = TRUE,
  simplify = FALSE,
  verbose = TRUE
)

Arguments

raster

RasterLayer.

steps_x, steps_y

Number of steps (cells) the raster is translated into the corresponding direction. If both are null, all possible combinations are used.

return_input

The original input data is returned as last list entry.

simplify

If n_random = 1 and return_input = FALSE only raster will be returned.

verbose

Print progress report.

Details

Torus translation test as described in Harms et al. (20001). The raster is shifted in all four cardinal directions by steps equal to the raste resolution. If a cell exits the extent on one side, it enters the extent on the opposite side.

Value

list

References

Harms, K. E., Condit, R., Hubbell, S. P., & Foster, R. B. (2001). Habitat associations of trees and shrubs in a 50-ha neotropical forest plot. Journal of Ecology, 89(6), 947-959.

See Also

randomize_raster

Examples

1
2
3
4
5
6
7
## Not run: 
landscape_classified <- classify_habitats(landscape, classes = 5)

landscape_random <- translate_raster(landscape_classified)
landscape_random_sub <- translate_raster(landscape_classified, steps_x = 1:10, steps_y = 1:5)

## End(Not run)

mhesselbarth/SHAR documentation built on Oct. 17, 2020, 8:58 p.m.