residuals: Calculate one-step-ahead (OSA) residuals for stochastic...

Description Usage Arguments Value References

View source: R/residuals.R

Description

This function is very time consuming and by default computes the one-step-ahead residual for the last 100 observations. See the function oneStepPredict and the paper in the references for more details.

Usage

1
residuals(object, conditional = 1:(object$nobs - 100), ...)

Arguments

object

A stochvolTMB object.

conditional

Index vector of observations that are fixed during OSA. By default the residuals of the last 100 observations are calculated. If set to NULL it will calculate one-step-ahead residuals for all observations.

...

Currently not used.

Value

Vector of one-step-ahead residuals. If the model is correctly specified, these should be standard normal.

References

https://www.researchgate.net/publication/316581864_Validation_of_ecological_state_space_models_using_the_Laplace_approximation


stochvolTMB documentation built on Aug. 13, 2021, 5:07 p.m.