Function for prediction at new locations for single-species integrated spatial occupancy models
Function for prediction at new locations for single-species integrated spatial occupancy models
The function predict collects posterior predictive samples for a set of new locations given an object of class spIntPGOcc.
## S3 method for class 'spIntPGOcc'predict(object, X.0, coords.0, n.omp.threads =1, verbose =TRUE, n.report =100, ignore.RE =FALSE, type ='occupancy',...)
Arguments
object: an object of class spIntPGOcc.
X.0: the design matrix for prediction locations. This should include a column of 1s for the intercept. Covariates should have the same column names as those used when fitting the model with spIntPGOcc.
coords.0: the spatial coordinates corresponding to X.0. Note that spOccupancy assumes coordinates are specified in a projected coordinate system.
n.omp.threads: a positive integer indicating the number of threads to use for SMP parallel processing. The package must be compiled for OpenMP support. For most Intel-based machines, we recommend setting n.omp.threads up to the number of hyperthreaded cores. Note, n.omp.threads > 1 might not work on some systems.
verbose: if TRUE, model specification and progress of the sampler is printed to the screen. Otherwise, nothing is printed to the screen.
n.report: the interval to report sampling progress.
ignore.RE: logical value that specifies whether or not to remove random occurrence (or detection if type = 'detection') effects from the subsequent predictions. If TRUE, random effects will be included. If FALSE, random effects will be set to 0 and predictions will only be generated from the fixed effects.
type: a quoted keyword indicating what type of prediction to produce. Valid keywords are 'occupancy' to predict latent occupancy probability and latent occupancy values (this is the default), or 'detection' to predict detection probability given new values of detection covariates. Note that prediction of detection probability is not currently supported for integrated models.