calculatePartialResiduals: Calculate Partial Residuals

View source: R/RcppExports.R

calculatePartialResidualsR Documentation

Calculate Partial Residuals

Description

Computes partial residuals for a selected covariate by adding the product of the regression coefficient and the corresponding design matrix value to the raw residual.

Usage

calculatePartialResiduals(y, fitted, X, beta, covariate_idx)

Arguments

y

NumericVector of observations.

fitted

NumericVector of fitted values.

X

NumericMatrix of design matrix values.

beta

NumericVector of regression coefficients.

covariate_idx

Integer index for the selected covariate (0-indexed).

Value

NumericVector of partial residuals.


gkwreg documentation built on April 16, 2025, 1:10 a.m.