Learn R Programming

binGroup2 (version 1.2.3)

residuals.gtReg: Extract model residuals from a fitted group testing model

Description

Extract model residuals from objects of class "gtReg" returned by gtReg.

Usage

# S3 method for gtReg
residuals(object, type = c("deviance", "pearson", "response"), ...)

Arguments

object

An object of class "gtReg", created by gtReg, from which the model residuals are to be extracted.

type

The type of residuals which should be returned. Options include "deviance" (default), "pearson", and "response".

...

currently not used.

Value

Residuals of group responses extracted from the object object.

Examples

Run this code
# NOT RUN {
data(hivsurv)
fit1 <- gtReg(formula = groupres ~ AGE * EDUC.,
              data = hivsurv, groupn = gnum,
              linkf = "probit")
residuals(object = fit1, type = "pearson")
residuals(object = fit1, type = "deviance")
# }

Run the code above in your browser using DataLab