Description Usage Arguments Value
View source: R/geo_joint_fit.r
Function to fit a either a spatial or spatio-temporal joint model to geo-statistical data with an intercept and covariates for each likelihood
1 2 3 4 5 6 7 8 | geo.joint.fit(mesh = NULL, locs = NULL, response = NULL, temp = NULL,
covariates = NULL, family = c("gaussian", "gaussian"),
control.time = list(model = "ar1", param = list(theta = list(prior =
"pccor1", param = c(0, 0.9)))), control.inla = list(strategy = "gaussian",
int.strategy = "eb"), hyper = list(theta = list(prior = "normal", param =
c(0, 10))), control.compute = list(dic = TRUE, waic = TRUE, cpo = TRUE,
config = TRUE), non.linear = NULL, sig0 = 1, Psig = 0.5, rho0 = 0.3,
Prho = 0.5, verbose = FALSE, ...)
|
mesh |
a “mesh” object i.e. delauney triangulation of the domain, an object returned by make.mesh. |
locs |
a list of matrcies. The first element holds observation locations for the first likelihood, where each row corresponds to an observation. The second elemenr holds the observation locations for the second likelihood, each row corresponds to an observation. If no second element is supplied the observation locations for the first likelihood are used. |
response |
a list (length two) of vectors of each response variable, each corresponds to the respective spatial locations
in |
temp |
(optional) a list of numeric vectors specifying the temporal indcies for each response respectively. |
covariates |
(optional) a list (length 2) each element should contain a named data.frame of covariates. The first corresponding to the first likelihood, the second corresponding the the second likelihood. |
family |
a character vector of length two specifying the assumed likelihood of each response, by default is c("gaussian","gaussian"). |
control.time |
(optional) supplied if the |
control.inla |
a list which controls the fitting procedures INLA uses see Rue et al. ***ref book***
by default this is |
hyper |
prior for the copy parameter by default is a N(0,10) i.e., list(theta=list(prior='normal', param=c(0,10))) |
control.compute |
a list of fit statistics the user wants INLA to return. By default this
is |
non.linear |
(optional) a list of named lists should be used if the user requires a non-linear covariate to be included for each likelihood. (i.e., non.linear = list(list(random.effect = idx.1, model = "iid"),list(random.effect = idx.2, model = "iid")) if the user wnats a iid effect for some idx.1 for the first likelihood and another for idx.2 for the second)
Must be supplied as a named list with elements |
sig0 |
by default = 1, typical standard deviation to use pc priors for hyperparams of spde model |
Psig |
by default = 0.5 prob for sigma of pc prior |
rho0 |
by default = 0.3, typical range to use pc priors for hyperparams of spde model |
Prho |
by default = 0.5 prob for rho of pc prior |
verbose |
Logical if |
... |
add inla options to speed up computation i.e., by giving starting values from a previos model |
A inla
result object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.