Modeling without covariates #168
Answered
by
ericward-noaa
joao-pompeu
asked this question in
Q&A
-
Hello sdmTMB team, It might be a silly question, but is it possible to model spatiotemporal distribution considering only coordinates, like a variogram? |
Beta Was this translation helpful? Give feedback.
Answered by
ericward-noaa
Jan 24, 2023
Replies: 1 comment
-
Yes—this is totally reasonable. For example, we might want to build an intercept only model, like the following. Here a spatial field is estimated (using coordinates) and the focus of inference would be on the spatial range, spatial variance, etc. You could also include spatiotemporal fields. library(sdmTMB)
mesh <- make_mesh(pcod_2011, c("X", "Y"), cutoff = 20)
# Fit a Tweedie spatial random field GLMM with an intercept
fit <- sdmTMB(
density ~ 1,
data = pcod_2011, mesh = mesh,
family = tweedie(link = "log")
)
fit
#> Spatial model fit by ML ['sdmTMB']
#> Formula: density ~ 1
#> Mesh: mesh (isotropic covariance)
#> Data: pcod_2011
#> Family: tweedie(link = 'log')
#>
#> coef.est coef.se
#> (Intercept) 3 0.43
#>
#> Dispersion parameter: 15.52
#> Tweedie p: 1.59
#> Matérn range: 33.23
#> Spatial SD: 2.03
#> ML criterion at convergence: 3023.736
#>
#> See ?tidy.sdmTMB to extract these values as a data frame. Created on 2023-03-08 with reprex v2.0.2 |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
seananderson
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes—this is totally reasonable. For example, we might want to build an intercept only model, like the following. Here a spatial field is estimated (using coordinates) and the focus of inference would be on the spatial range, spatial variance, etc. You could also include spatiotemporal fields.