The hardware and bandwidth for this mirror is donated by dogado GmbH, the Webhosting and Full Service-Cloud Provider. Check out our Wordpress Tutorial.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]dogado.de.

SpatialInference: Tools for Statistical Inference with Geo-Coded Data

Fast computation of Conley (1999) <doi:10.1016/S0304-4076(98)00084-0> spatial heteroskedasticity and autocorrelation consistent (HAC) standard errors for linear regression models with geo-coded data, with a fast C++ implementation by Christensen, Hartman, and Samii (2021) <doi:10.1017/S0020818321000187>. Performance-critical distance calculations, kernel weighting, and variance component accumulation are implemented in C++ via 'Rcpp' and 'RcppArmadillo'. Includes tools for estimating the spatial correlation range from covariograms and correlograms following the bandwidth selection method proposed in Lehner (2026) <doi:10.48550/arXiv.2603.03997>, and diagnostic visualizations for bandwidth selection.

Version: 0.1.0
Depends: R (≥ 4.1.0)
Imports: Rcpp, sf, data.table, magrittr, stats, tibble
LinkingTo: Rcpp, RcppArmadillo
Suggests: lfe, fixest, dplyr, stringr, spdep, ncf, gstat, sandwich, ggplot2, modelsummary, knitr, rmarkdown, geosphere, testthat (≥ 3.0.0)
Published: 2026-03-25
DOI: 10.32614/CRAN.package.SpatialInference
Author: Alexander Lehner ORCID iD [aut, cre]
Maintainer: Alexander Lehner <alehner at worldbank.org>
BugReports: https://github.com/axlehner/SpatialInference/issues
License: GPL (≥ 3)
URL: https://github.com/axlehner/SpatialInference
NeedsCompilation: yes
Materials: README, NEWS
CRAN checks: SpatialInference results

Documentation:

Reference manual: SpatialInference.html , SpatialInference.pdf
Vignettes: spatial_HAC (source, R code)

Downloads:

Package source: SpatialInference_0.1.0.tar.gz
Windows binaries: r-devel: SpatialInference_0.1.0.zip, r-release: SpatialInference_0.1.0.zip, r-oldrel: SpatialInference_0.1.0.zip
macOS binaries: r-release (arm64): SpatialInference_0.1.0.tgz, r-oldrel (arm64): not available, r-release (x86_64): SpatialInference_0.1.0.tgz, r-oldrel (x86_64): SpatialInference_0.1.0.tgz

Linking:

Please use the canonical form https://CRAN.R-project.org/package=SpatialInference to link to this page.

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.
Health stats visible at Monitor.