powered by
Calculates and plots a correlogram
correlogram(x, v, dist = 5000, dmatrix = FALSE, ns = 99, latlong = FALSE, ...)
SpatialPointsDataFrame object
Test variable in x@data
Distance of correlation lags, if latlong=TRUE units are in kilometers
Should the distance matrix be include in output (TRUE/FALSE)
Number of simulations to derive simulation envelope
Coordinates are in latlong (TRUE/FALSE)
Arguments passed to cor ('pearson', 'kendall' or 'spearman')
A list object containing:
autocorrelation is a data.frame object with the following components
autocorrelation - Autocorrelation value for each distance lag
dist - Value of distance lag
lci - Lower confidence interval (p=0.025)
uci - Upper confidence interval (p=0.975)
CorrPlot recordedplot object to recall plot
dmatrix Distance matrix (if dmatrix=TRUE)
# NOT RUN { library(sp) data(meuse) coordinates(meuse) = ~x+y zinc.cg <- correlogram(x = meuse, v = meuse@data[,'zinc'], dist = 250, ns = 9) # }
Run the code above in your browser using DataLab