residuals.pclm2D: Extract PCLM-2D Deviance Residuals

View source: R/pclm_2D.R

residuals.pclm2DR Documentation

Extract PCLM-2D Deviance Residuals

Description

Extract PCLM-2D Deviance Residuals

Usage

## S3 method for class 'pclm2D'
residuals(object, ...)

Arguments

object

an object for which the extraction of model residuals is meaningful.

...

other arguments.

Value

Residuals extracted from the object object.

Examples


Dx <- ungroup.data$Dx
Ex <- ungroup.data$Ex

# Aggregate data to ungroup it in the example below
x      <- c(0, 1, seq(5, 85, by = 5))
nlast  <- 26
n      <- c(diff(x), nlast)
group  <- rep(x, n)
y      <- aggregate(Dx, by = list(group), FUN = "sum")[, -1]

# Example
P1 <- pclm2D(x, y, nlast)

residuals(P1)

mpascariu/pclm documentation built on Feb. 4, 2024, 9:34 p.m.