fitDeltaGLM | R Documentation |
This function writes, and optionally runs the model in the BUGS/JAGS framework
fitDeltaGLM(
datalist = NULL,
modelStructure = list(StrataYear.positiveTows = "random", VesselYear.positiveTows =
"random", StrataYear.zeroTows = "random", VesselYear.zeroTows = "random",
Vessel.positiveTows = "zero", Vessel.zeroTows = "zero", Catchability.positiveTows =
"one", Catchability.zeroTows = "zero", year.deviations = "uncorrelated",
strata.deviations = "uncorrelated"),
covariates = list(positive = FALSE, binomial = FALSE),
likelihood = "gamma",
model.name = "deltaGLM.txt",
fit.model = TRUE,
write.model = TRUE,
mcmc.control = list(chains = 5, thin = 1, burn = 5000, iterToSave = 2000),
Parallel = TRUE,
Species = "NULL",
logitBounds = c(-20, 20),
logBounds = c(-20, 20),
prior.scale = rep(25, 6),
dgammaNum = 0.001
)
datalist |
List of data passed in |
modelStructure |
list controlling mdoel components
|
covariates |
Two element vector specifying whether covariates are included.
|
likelihood |
Character string specifying the form of the positive model. Can be one of the following: "gamma" (or "gammaFixedCV"), "lognormal" (or "lognormalFixedCV"), "invGaussian" (or "invGaussianFixedCV"), "lognormalECE", "gammaECE", "poisson", "zt_poisson", or "negbin". Defaults to "gamma". The forms of the model are as follows:
|
model.name |
Character string specifying the name of the JAGS txt file that is written to the working directory. Defaults "to deltaGLM.txt" |
fit.model |
Boolean, specifying whether the model should be fit or not. Defaults to TRUE; if FALSE, just the JAGS script file is written. |
write.model |
Boolean, whether to write model to a file. Defaults to TRUE |
mcmc.control |
List of parameter to control MCMC estimation
|
Parallel |
Whether to conduct estimation using parallel computing (faster), using the function jags.parallel(). |
Species |
Species name, defaults to "NULL" |
logitBounds |
2 element vector specifying bounds of logit link space. Defaults c(-20,20) |
logBounds |
2 element vector specifying bounds of log link space. Defaults c(-20,20) |
prior.scale |
Scale parameter for the variance parameter of the "randomExpanded" random effects. This is a 6 element vector, defaults to (25, 25, 25, 25, 25, 25), where the elements are (strataYear.positive, strataYear.presenceAbsence, vesselYear.positive, vesselYear.presenceAbsence, vessel.positive, vessel.presenceAbsence) |
dgammaNum |
Prior on precision parameters, e.g. tau ~ dgamma(dgammaNum, dgammaNum). Defaults to 0.001 |
list of the following
fitted model object
function call, for reproducibility
estimated parameters
Species name
Data used to estimate parameters
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.