Learn R Programming

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

spdep (version 0.6-4)

Spatial Dependence: Weighting Schemes, Statistics and Models

Description

A collection of functions to create spatial weights matrix objects from polygon contiguities, from point patterns by distance and tessellations, for summarizing these objects, and for permitting their use in spatial data analysis, including regional aggregation by minimum spanning tree; a collection of tests for spatial autocorrelation, including global Moran's I, APLE, 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 and exact tests for global and local Moran's I; and functions for estimating spatial simultaneous autoregressive (SAR) lag and error models, impact measures for lag models, weighted and unweighted SAR and CAR spatial regression models, semi-parametric and Moran eigenvector spatial filtering, GM SAR error models, and generalized spatial two stage least squares models.

Copy Link

Version

Install

install.packages('spdep')

Monthly Downloads

40,858

Version

0.6-4

License

GPL (>= 2)

Maintainer

Roger Bivand

Last Published

April 12th, 2016

Functions in spdep (0.6-4)

aggregate.nb

Aggregate a spatial neighbours object
cell2nb

Generate neighbours list for grid cells
moran.mc

Permutation test for Moran's I statistic
house

Lucas county OH housing
SpatialFiltering

Semi-parametric spatial filtering
nb2mat

Spatial weights matrices for neighbours lists
diffnb

Differences between neighbours lists
plot.mst

Plot the Minimum Spanning Tree
bhicv

Data set with 4 life condition indices of Belo Horizonte region
joincount.multi

BB, BW and Jtot join count statistic for k-coloured factors
joincount.test

BB join count statistic for k-coloured factors
boston

Corrected Boston Housing Data
mstree

Find the minimal spanning tree
afcon

Spatial patterns of conflict in Africa 1966-78
similar.listw

Create symmetric similar weights lists
nblag

Higher order neighbours lists
errorsarlm

Spatial simultaneous autoregressive error model estimation
as_dgRMatrix_listw

Interface between Matrix class objects and weights lists
lm.morantest.sad

Saddlepoint approximation of global Moran's I test
LR.sarlm

Likelihood ratio test
dnearneigh

Neighbourhood contiguity by distance
ME

Moran eigenvector GLM filtering
globalG.test

Global G test for spatial autocorrelation
EBest

Global Empirical Bayes estimator
huddersfield

Prevalence of respiratory symptoms
nbcosts

Compute cost of edges
card

Cardinalities for neighbours lists
poly2nb

Construct neighbours list from polygon list
choynowski

Choynowski probability map values
write.nb.gal

Write a neighbours list as a GAL lattice file
summary.sarlm

summary method for class sarlm
read.gal

Read a GAL lattice file into a neighbours list
plot.nb

Plot a neighbours list
subset.nb

Subset a neighbours list
geary

Compute Geary's C
droplinks

Drop links in a neighbours list
GMerrorsar

Spatial simultaneous autoregressive error model estimation by GMM
knearneigh

K nearest neighbours for spatial weights
include.self

Include self in neighbours list
geary.test

Geary's C test for spatial autocorrelation
nc.sids

North Carolina SIDS data
Graph Components

Depth First Search on Neighbor Lists
localmoran.sad

Saddlepoint approximation of local Moran's Ii tests
nbdists

Spatial link distance measures
lag.listw

Spatial lag of a numeric vector
prunemst

Prune a Minimun Spanning Tree
airdist

Measure distance from plot
plot.skater

Plot the object of skater class
EBlocal

Local Empirical Bayes estimator
read.gwt2nb

Read and write spatial neighbour files
eire

Eire data sets
sp.mantel.mc

Mantel-Hubert spatial general cross product statistic
nb2lines

Use arc-type shapefiles for import and export of weights
moran.plot

Moran scatterplot
tolerance.nb

Function to construct edges based on a tolerance angle and a maximum distance
getisord

Getis-Ord remote sensing example data
lm.LMtests

Lagrange Multiplier diagnostics for spatial dependence in linear models
oldcol

Columbus OH spatial analysis data set - old numbering
eigenw

Spatial weights matrix eigenvalues
joincount.mc

Permutation test for same colour join count statistics
p.adjustSP

Adjust local association measures' p-values
bptest.sarlm

Breusch-Pagan test for spatial models
lee

Compute Lee's statistic
elect80

1980 Presidential election results
do_ldet

Spatial regression model Jacobian computations
nb.set.operations

Set operations on neighborhood objects
probmap

Probability mapping for rates
lm.morantest.exact

Exact global Moran's I test
set.spChkOption

Control checking of spatial object IDs
edit.nb

Interactive editing of neighbours lists
is.symmetric.nb

Test a neighbours list for symmetry
aple.mc

Approximate profile-likelihood estimator (APLE) permutation test
localmoran.exact

Exact local Moran's Ii tests
spdep

Return package version number
nb2INLA

Output spatial neighbours for INLA
invIrM

Compute SAR generating operator
aple.plot

Approximate profile-likelihood estimator (APLE) scatterplot
knn2nb

Neighbours list from knn object
aple

Approximate profile-likelihood estimator (APLE)
mat2listw

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

Matrix exponential spatial lag model
auckland

Marshall's infant mortality in Auckland dataset
nb2WB

Output spatial weights for WinBUGS
summary.nb

Print and summary function for neighbours and weights lists
EBImoran.mc

Permutation test for empirical Bayes index
predict.sarlm

Prediction for spatial simultaneous autoregressive linear model objects
lagsarlm

Spatial simultaneous autoregressive lag model estimation
used.cars

US 1960 used car prices
NY_data

New York leukemia data
hopkins

Hopkins burnt savanna herb remains
tri2nb

Neighbours list from tri object
MCMCsamp

MCMC sample from fitted spatial regression
moran

Compute Moran's I
localG

G and Gstar local spatial statistics
sp.correlogram

Spatial correlogram
nb2blocknb

Block up neighbour list for location-less observations
anova.sarlm

Comparison of simultaneous autoregressive models
residuals.sarlm

Access functions for spatial simultaneous autoregressive linear model objects
columbus

Columbus OH spatial analysis data set
impacts

Impacts in spatial lag models
Rotation

Rotate a set of point by a certain angle
autocov_dist

Distance-weighted autocovariate
prunecost

Compute cost of prune each edge
lee.mc

Permutation test for Lee's L statistic
lm.morantest

Moran's I test for residual spatial autocorrelation
skater

Spatial 'K'luster Analysis by Tree Edge Removal
lee.test

Lee's L test for spatial autocorrelation
localmoran

Local Moran's I statistic
trW

Spatial weights matrix powers traces
set.mcOption

Options for parallel support
moran.test

Moran's I test for spatial autocorrelation
subset.listw

Subset a spatial weights list
nb2listw

Spatial weights for neighbours lists
sacsarlm

Spatial simultaneous autoregressive SAC model estimation
ssw

Compute the sum of dissimilarity
spweights.constants

Provides constants for spatial weights matrices
wheat

Mercer and Hall wheat yield data
baltimore

House sales prices, Baltimore, MD 1978
stsls

Generalized spatial two stage least squares
gstsls

Spatial simultaneous autoregressive SAC model estimation by GMM
listw2sn

Spatial neighbour sparse representation
geary.mc

Permutation test for Geary's C statistic
graphneigh

Graph based spatial weights
lextrB

Find extreme eigenvalues of binary symmetric spatial weights
spautolm

Spatial conditional and simultaneous autoregression model estimation