View source: R/residuals.mpmm.r
residuals.mpmm | R Documentation |
Extract one-step-ahead residuals
## S3 method for class 'mpmm' residuals( object, method = "oneStepGaussianOffMode", trace = FALSE, parallel = TRUE, ncores = detectCores() - 1, ... )
object |
an mpmm fit object |
method |
character naming the method to calculate one-step-ahead residuals |
trace |
logical; print progress to console |
parallel |
logical; compute in parallel |
ncores |
integer; number of cores to use (default = total cores detected - 1) |
... |
additional arguments to be ignored |
Wrapper function for modified oneStepPredict
that calculates one-step-ahead residuals, which are residuals that account
for temporal correlation in latent states. The modification allows easier
parallel computation.
a list with components
|
a tibble with one-step-ahead residuals for longitude and latitude |
Thygesen, U. H., C. M. Albertsen, C. W. Berg, K. Kristensen, and A. Neilsen. 2017. Validation of ecological state space models using the Laplace approximation. Environmental and Ecological Statistics 24:317–339.
## Not run: data(ellie.ice) fit <- mpmm(~ ice + (1 | id), data = ellie.ice) summary(fit) residuals(fit) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.