residuals.tsglm

0th

Percentile

Residuals of a Generalised Linear Model for Time Series of Counts

Returns the residuals of a fitted GLM-type model for time series of counts.

Keywords
Model assessment
Usage
"residuals"(object, type = c("response", "pearson", "anscombe"), ...)
Arguments
object
an object of class "tsglm". Usually the result of a call to tsglm.
type
character value giving the type of residuals which should be returned. Choose type="response" for raw residuals, type="pearson" for Pearson residuals and type="anscombe" for Anscombe residuals.
...
further arguments are currently ignored. Only for compatibility with generic function.
Details

Computes a vector with the respective residuals of the fit given in argument object.

Value

Numerical vector of the residuals.

See Also

tsglm for fitting a GLM for time series of counts.

Aliases
  • residuals.tsglm
Examples
###Campylobacter infections in Canada (see help("campy"))
campyfit <- tsglm(ts=campy, model=list(past_obs=1, past_mean=c(7,13)))
campyfit_resid <- residuals(campyfit, type="pearson")
plot(campyfit_resid)
acf(campyfit_resid)
Documentation reproduced from package tscount, version 1.3.0, License: GPL-2 | GPL-3

Community examples

Looks like there are no examples yet.