Package 'strucchangeArmadillo'

Title: C++ Speedup Functions for strucchange Using the Armadillo Library
Description: C++ speedup functions for srucchange using the Armadillo library.
Authors: Marius Appel [aut] (ORCID: <https://orcid.org/0000-0001-5281-3896>), Achim Zeileis [ctb, cre] (ORCID: <https://orcid.org/0000-0003-0918-3766>)
Maintainer: Achim Zeileis <[email protected]>
License: GPL-2 | GPL-3
Version: 1.5-1.1
Built: 2026-10-01 12:31:17 UTC
Source: https://codeberg.org/zeileis/strucchangeArmadillo

Help Index


Recursive Residuals Using the C++ Armadillo Library

Description

Function for computing the recursive residuals (standardized one step prediction errors) of a linear regression model using the C++ Armadillo library.

Usage

recresid_cpp(x, y, start = ncol(x) + 1, end = nrow(x),
  tol = sqrt(.Machine$double.eps)/ncol(x), ...)

Arguments

x, y

specification of the linear regression model by a regressor matrix x and a response variable y.

start, end

integer. Index of the first and last observation, respectively, for which recursive residuals should be computed. By default, the maximal range is selected.

tol

numeric. A relative tolerance for precision of recursive coefficient estimates, see details.

...

currently not used.

Details

See function recresid.

Value

A vector containing the recursive residuals.

See Also

recresid

Examples

y <- rnorm(100) + rep(c(0, 2), each = 50)
x <- matrix(1, nrow = 100, ncol = 1)
rr <- recresid_cpp(x, y)
print(rr)