residuals.circGLM: Obtain residuals from a circGLM object

Description Usage Arguments Value Examples

View source: R/circGLMClassFunctions.R

Description

Computes the residuals either by taking the arc distance or the cosine distance between the predictions and the observed outcomes.

Usage

1
2
## S3 method for class 'circGLM'
residuals(object, type = "arc", ...)

Arguments

object

A circGLM object.

type

Either "arc" or "cosine", the type of distance to take.

...

Further arguments passed to or from other methods.

Value

A numeric vector of residuals. If type is "arc", these are angles in radians. If type is "cosine", these are numeric values between 0 and 2.

Examples

1
2
3
4
5
m <- circGLM(th = rvmc(10, 0, 1))
residuals(m)

# Cosine residuals
residuals(m, type = "cosine")

circglmbayes documentation built on Jan. 22, 2021, 5:09 p.m.