spmodel
Spatial Statistical Modeling and Prediction
Description
Fit, summarize, and predict for a variety of spatial statistical models applied to point-referenced and areal (lattice) data. Parameters are estimated using various methods. Additional modeling features include anisotropy, non-spatial random effects, partition factors, big data approaches, and more. Model-fit statistics are used to summarize, visualize, and compare models. Predictions at unobserved locations are readily obtainable. For additional details, see Dumelle et al. (2023) <doi:10.1371/journal.pone.0282524>.
Downloads
750
Last 30 days
4813th
2.3K
Last 90 days
11.5K
Last year
Trend: +14.5% (30d vs prior 30d)
CRAN Check Status
Show all 14 flavors
| Flavor | Status |
|---|---|
| r-devel-linux-x86_64-debian-clang | OK |
| r-devel-linux-x86_64-debian-gcc | OK |
| r-devel-linux-x86_64-fedora-clang | ERROR |
| r-devel-linux-x86_64-fedora-gcc | ERROR |
| r-devel-macos-arm64 | OK |
| r-devel-windows-x86_64 | OK |
| r-oldrel-macos-arm64 | NOTE |
| r-oldrel-macos-x86_64 | NOTE |
| r-oldrel-windows-x86_64 | NOTE |
| r-patched-linux-x86_64 | OK |
| r-release-linux-x86_64 | OK |
| r-release-macos-arm64 | OK |
| r-release-macos-x86_64 | OK |
| r-release-windows-x86_64 | OK |
Check details (7 non-OK)
examples
Running examples in ‘spmodel-Ex.R’ failed
The error most likely occurred in:
> ### Name: augment.spmodel
> ### Title: Augment data with information from fitted model objects
> ### Aliases: augment.spmodel augment.splm augment.spautor augment.spglm
> ### augment.spgautor
>
> ### ** Examples
>
> spmod <- splm(z ~ water + tarp,
+ data = caribou,
+ spcov_type = "exponential", xcoord = x, ycoord = y
+ )
> augment(spmod)
# A tibble: 30 × 10
z water tarp x y .fitted .resid .hat .cooksd .std.resid
<dbl> <fct> <fct> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
1 2.42 Y clear 1 6 1.97 0.454 0.116 0.209 2.53
2 2.44 Y shade 2 6 2.25 0.190 0.137 0.0468 1.09
3 1.81 Y none 3 6 2.05 -0.237 0.137 0.0752 -1.38
4 1.97 N clear 4 6 2.05 -0.0838 0.174 0.00211 -0.200
5 2.38 N shade 5 6 2.34 0.0407 0.153 0.0159 0.594
6 2.22 Y none 1 5
...[truncated]...
5.92 7.00 0.00334 0.00161 -0.694 (817738.8 1080571)
2 20.2 5.92 14.2 0.00256 0.00192 0.865 (914593.6 1295545)
3 16.8 5.92 10.9 0.00259 0.000395 0.390 (359574.1 1178228)
4 16.2 5.92 10.3 0.00239 0.000363 0.390 (265331.9 1239089)
5 7.86 5.92 1.93 0.00202 0.00871 -2.07 (304528.8 1453636)
6 15.4 5.92 9.43 0.00201 0.000240 0.345 (162932.8 1451625)
7 0.986 5.92 -4.94 0.00380 0.000966 -0.503 (-1437776 1568022)
8 0.425 5.92 -5.50 0.0138 0.00584 -0.646 (-1572878 1125529)
9 3.58 5.92 -2.34 0.00673 0.0000148 -0.0467 (-1282009 1204889)
10 2.38 5.92 -3.54 0.0123 0.0000139 -0.0335 (-1972775 1464991)
# ℹ 187 more rows
> augment(spmod_sulf, newdata = sulfate_preds)
OMP: Warning #96: Cannot form a team with 24 threads, using 2 instead.
OMP: Hint Consider unsetting KMP_DEVICE_THREAD_LIMIT (KMP_ALL_THREADS), KMP_TEAMS_THREAD_LIMIT, and OMP_THREAD_LIMIT (if any are set).
re-building of vignette outputs
Error(s) in re-building vignettes: --- re-building ‘introduction.Rmd’ using rmarkdown OMP: Warning #96: Cannot form a team with 24 threads, using 2 instead. OMP: Hint Consider unsetting KMP_DEVICE_THREAD_LIMIT (KMP_ALL_THREADS), KMP_TEAMS_THREAD_LIMIT, and OMP_THREAD_LIMIT (if any are set).
examples
Running examples in ‘spmodel-Ex.R’ failed
The error most likely occurred in:
> ### Name: augment.spmodel
> ### Title: Augment data with information from fitted model objects
> ### Aliases: augment.spmodel augment.splm augment.spautor augment.spglm
> ### augment.spgautor
>
> ### ** Examples
>
> spmod <- splm(z ~ water + tarp,
+ data = caribou,
+ spcov_type = "exponential", xcoord = x, ycoord = y
+ )
> augment(spmod)
# A tibble: 30 × 10
z water tarp x y .fitted .resid .hat .cooksd .std.resid
<dbl> <fct> <fct> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
1 2.42 Y clear 1 6 1.97 0.454 0.116 0.209 2.53
2 2.44 Y shade 2 6 2.25 0.190 0.137 0.0468 1.09
3 1.81 Y none 3 6 2.05 -0.237 0.137 0.0752 -1.38
4 1.97 N clear 4 6 2.05 -0.0838 0.174 0.00211 -0.200
5 2.38 N shade 5 6 2.34 0.0407 0.153 0.0159 0.594
6 2.22 Y none 1 5
...[truncated]...
d CRS: NAD83 / Conus Albers
# A tibble: 197 × 7
sulfate .fitted .resid .hat .cooksd .std.resid geometry
* <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <POINT [m]>
1 12.9 5.92 7.00 0.00334 0.00161 -0.694 (817738.8 1080571)
2 20.2 5.92 14.2 0.00256 0.00192 0.865 (914593.6 1295545)
3 16.8 5.92 10.9 0.00259 0.000395 0.390 (359574.1 1178228)
4 16.2 5.92 10.3 0.00239 0.000363 0.390 (265331.9 1239089)
5 7.86 5.92 1.93 0.00202 0.00871 -2.07 (304528.8 1453636)
6 15.4 5.92 9.43 0.00201 0.000240 0.345 (162932.8 1451625)
7 0.986 5.92 -4.94 0.00380 0.000966 -0.503 (-1437776 1568022)
8 0.425 5.92 -5.50 0.0138 0.00584 -0.646 (-1572878 1125529)
9 3.58 5.92 -2.34 0.00673 0.0000148 -0.0467 (-1282009 1204889)
10 2.38 5.92 -3.54 0.0123 0.0000139 -0.0335 (-1972775 1464991)
# ℹ 187 more rows
> augment(spmod_sulf, newdata = sulfate_preds)
re-building of vignette outputs
Error(s) in re-building vignettes: --- re-building ‘introduction.Rmd’ using rmarkdown
installed package size
installed size is 5.8Mb
sub-directories of 1Mb or more:
R 2.0Mb
data 1.7Mb
doc 1.5Mb
installed package size
installed size is 5.9Mb
sub-directories of 1Mb or more:
R 2.0Mb
data 1.8Mb
doc 1.5Mb
installed package size
installed size is 5.0Mb
sub-directories of 1Mb or more:
R 1.2Mb
data 1.7Mb
doc 1.5Mb
Check History
ERROR 9 OK · 3 NOTE · 0 WARNING · 2 ERROR · 0 FAILURE Mar 10, 2026
examples
Running examples in ‘spmodel-Ex.R’ failed The error most likely occurred in: > ### Name: augment.spmodel > ### Title: Augment data with information from fitted model objects > ### Aliases: augment.spmodel augment.splm augment.spautor augment.spglm > ...[truncated]... augment(spmod_sulf, newdata = sulfate_preds) OMP: Warning #96: Cannot form a team with 24 threads, using 2 instead. OMP: Hint Consider unsetting KMP_DEVICE_THREAD_LIMIT (KMP_ALL_THREADS), KMP_TEAMS_THREAD_LIMIT, and OMP_THREAD_LIMIT (if any are set).
examples
Running examples in ‘spmodel-Ex.R’ failed The error most likely occurred in: > ### Name: augment.spmodel > ### Title: Augment data with information from fitted model objects > ### Aliases: augment.spmodel augment.splm augment.spautor augment.spglm > ...[truncated]... 00584 -0.646 (-1572878 1125529) 9 3.58 5.92 -2.34 0.00673 0.0000148 -0.0467 (-1282009 1204889) 10 2.38 5.92 -3.54 0.0123 0.0000139 -0.0335 (-1972775 1464991) # ℹ 187 more rows > augment(spmod_sulf, newdata = sulfate_preds)
installed package size
installed size is 5.8Mb
sub-directories of 1Mb or more:
R 2.0Mb
data 1.7Mb
doc 1.5Mb
installed package size
installed size is 5.9Mb
sub-directories of 1Mb or more:
R 2.0Mb
data 1.8Mb
doc 1.5Mb
installed package size
installed size is 5.0Mb
sub-directories of 1Mb or more:
R 1.2Mb
data 1.7Mb
doc 1.5Mb