Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

variogram

Empirical Variogram from Spatial Data


Description

Compute sample (empirical) variogram from spatial data. The function returns a binned variogram and a variogram cloud.

Usage

Variogram(x, width, cutoff,...)

Arguments

x

a spatial object (RasterLayer or SpatialPointsDataFrame or SpatialPolygonsDataFrame)

width

the lag size (width of subsequent distance intervals) into which cell pairs are grouped for semivariance estimates. If missing, the cell size (raster resolution) is assigned.

cutoff

spatial separation distance up to which cell pairs are included in semivariance estimates; as a default, the length of the diagonal of the box spanning the data is divided by three.

...

Additional arguments including cloud that specifies whether a variogram cloud should be included to the output (default is FALSE), zcol (when x is Spatial* object, specifies the name of the variable in the dataset; longlat (when x is Spatial* object, spacifies whether the dataset has a geographic coordinate system; s (only when x is a Raster object, it would be useful when the dataset is big, so then by specifying s, the calculation would be based on a sample with size s drawn from the dataset, default is NULL means all cells should be contributed in the calculations)

Details

Variogram is a graph to explore spatial structure in a single variable. A variogram summarizes the spatial relations in the data, and can be used to understand within what range (distance) the data is spatially autocorrelated.

Value

Variogram

an object containing variogram cloud and the variogram within each distance interval

Author(s)

Babak Naimi naimi.b@gmail.com

References

Naimi, B., Hamm, N. A., Groen, T. A., Skidmore, A. K., Toxopeus, A. G., & Alibakhshi, S. (2019). ELSA: Entropy-based local indicator of spatial association. Spatial statistics, 29, 66-88.

Examples

file <- system.file('external/dem_example.grd',package='elsa')
r <- raster(file)
plot(r,main='a continuous raster map')

en <- Variogram(r, width=2000)

plot(en)

elsa

Entropy-Based Local Indicator of Spatial Association

v1.1-28
GPL (>= 3)
Authors
Babak Naimi [cre, aut] (<https://orcid.org/0000-0001-5431-2729>), Roger Bivand [ctb] (part of the dnn C code, from the spdep package), William Venables [ctb] (part of the dnn C code, taken from the spdep package), Brian Ripley [ctb] (part of the dnn C code, taken from the spdep package)
Initial release
2020-03-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.