Compute Residuals for a bdGlm Object

DESCRIPTION:

Computes one of the four types of residuals available for bdGlm objects.

This function requires the bigdata library section to be loaded.

USAGE:

residuals.bdGlm(object, type) 
This is a method for the function residuals for objects inheriting from class "bdGlm". However, as several types of residuals are available for bdGlm objects, there is an additional optional argument type.

REQUIRED ARGUMENTS:

object
an object inheriting from class "bdGlm" representing a fitted model.

OPTIONAL ARGUMENTS:

type
type of residuals, with choices "deviance", "pearson", "working" or "response"; the first is the default.

VALUE:

a bdNumeric vector of residuals. See Statistical Models in Sfor detailed definitions of each type of residual. The sum of squared deviance residuals add up to the deviance. The pearson residuals are standardized residuals on the scale of the response. The working residuals reside on the object, and are the residuals from the final IRLS fit. The response residuals are simply y-fitted(object) . The residuals component of a bdGlm object contains the working residuals.

REFERENCES:

Chambers, J. M., and Hastie, T. J. (1991). Statistical Models in S, pp. 204--206.

SEE ALSO:

EXAMPLES:

bigKyph <- as.bdFrame(kyphosis)
kyph.bdGlm <- glm(Kyphosis ~ ., binomial, data=bigKyph)
residuals(kyph.bdGlm, type='response')