Learn R Programming

⚠️There's a newer version (1.3-10) of this package.Take me there.

spdep (version 0.3-8)

Spatial dependence: weighting schemes, statistics and models

Description

A collection of functions to create spatial weights matrix objects from polygon contiguities (including the creation of polygon lists from imported shapefiles), from point patterns by distance and tesselations, for summarising these objects, and for permitting their use in spatial data analysis; a collection of tests for spatial autocorrelation, including global Moran's I, Geary's C, Hubert/Mantel general cross product statistic, Empirical Bayes estimates and Assun��o/Reis Index, Getis/Ord G and multicoloured join count statistics, local Moran's I and Getis/Ord G, saddlepoint approximations for global and local Moran's I; and functions for estimating spatial simultaneous autoregressive (SAR) models.

Copy Link

Version

Install

install.packages('spdep')

Monthly Downloads

40,443

Version

0.3-8

License

GPL version 2 or newer

Maintainer

Roger Bivand

Last Published

January 20th, 2025

Functions in spdep (0.3-8)

set.spChkOption

Control checking of spatial object IDs
lm.morantest.sad

Saddlepoint approximation of global Moran's I test
nb.set.operations

Set operations on neighborhood objects
nb2blocknb

Block up neighbour list for location-less observations
localG

G and Gstar local spatial statistics
airdist

Measure distance from plot
dnearneigh

Neighbourhood contiguity by distance
droplinks

Drop links in a neighbours list
knn2nb

Neighbours list from knn object
is.symmetric.nb

Test a neighbours list for symmetry
moran.test

Moran's I test for spatial autocorrelation
joincount.mc

Permutation test for same colour join count statistics
edit.nb

Interactive editing of neighbours lists
similar.listw

Create symmetric similar weights lists
EBest

Global Empirical Bayes estimator
subset.nb

Subset a neighbours list
errorsarlm

Spatial simultaneous autoregressive error model estimation
moran.mc

Permutation test for Moran's I statistic
asMatrixCsrListw

Convert spatial weights list to CSR matrix form
anova.sarlm

Comparison of simultaneous autoregressive models
p.adjustSP

Adjust local association measures' p-values
residuals.sarlm

Access functions for spatial simultaneous autoregressive linear model objects
tri2nb

Neighbours list from tri object
sp.correlogram

Spatial correlogram
LR.sarlm

Likelihood ratio test
geary.test

Geary's C test for spatial autocorrelation
graphneigh

Graph based spatial weights
EBlocal

Local Empirical Bayes estimator
nb2listw

Spatial weights for neighbours lists
EBImoran.mc

Permutation test for empirical Bayes index
predict.sarlm

Prediction for spatial simultaneous autoregressive linear model objects
card

Cardinalities for neighbours lists
baltimore

House sales prices, Baltimore, MD 1978
moran.plot

Moran scatterplot
nbdists

Spatial link distance measures
choynowski

Choynowski probability map values
read.gwt2nb

Read and write spatial neighbour files
knearneigh

K nearest neighbours for spatial weights
hopkins

Hopkins burnt savanna herb remains
eigenw

Spatial weights matrix eigenvalues
globalG.test

test for spatial autocorrelation
joincount.test

BB join count statistic for k-coloured factors
lm.LMtests

Lagrange Multiplier diagnostics for spatial dependence in linear models
spweights.constants

Provides constants for spatial weights matrices
bptest.sarlm

Breusch-Pagan test for spatial models
mat2listw

Convert a square spatial weights matrix to a weights list object
listw2sn

Spatial neighbour sparse representation
moran

Compute Moran's I
localmoran.sad

Saddlepoint approximation of local Moran's Ii tests
diffnb

Differences between neighbours lists
summary.sarlm

summary method for class sarlm
nblag

Higher order neighbours lists
poly2nb

Construct neighbours list from polygon list
localmoran

Local Moran's I statistic
subset.listw

Subset a spatial weights list
sp.mantel.mc

Mantel-Hubert spatial general cross product statistic
include.self

Include self in neighbours list
geary.mc

Permutation test for Geary's C statistic
nb2mat

Spatial weights matrices for neighbours lists
lm.morantest

Moran's I test for residual spatial autocorrelation
plot.nb

Plot a neighbours list
cell2nb

Generate neighbours list for grid cells
read.gal

Read a GAL lattice file into a neighbours list
Graph Components

Depth First Search on Neighbor Lists
joincount.multi

BB, BW and Jtot join count statistic for k-coloured factors
geary

Compute Geary's C
lagsarlm

Spatial simultaneous autoregressive lag model estimation
invIrM

Compute SAR generating operator
lag.listw

Spatial lag of a numeric vector
spdep

Return package version number
probmap

Probability mapping for rates
summary.nb

Print and summary function for neighbours and weights lists
write.nb.gal

Write a neighbours list as a GAL lattice file
afcon

Spatial patterns of conflict in Africa 1966-78
eire

Eire data sets
columbus

Columbus OH spatial analysis data set
getisord

Getis-Ord remote sensing example data
boston

Corrected Boston Housing Data
nc.sids

North Carolina SIDS data
auckland

Marshall's infant mortality in Auckland dataset
used.cars

US 1960 used car prices
oldcol

Columbus OH spatial analysis data set - old numbering