Learn R Programming

nlr (version 0.1-3)

transformNR: Transform nonlinear regression model

Description

Transform both side a nonlinear regression model by cholesky decomposition of covariance matrix of errors. The new transformed model has constant variance and uncorrelated errors.

  • transform: Transform using rm matrix

  • transforminv: Inverse transform using inverse of rm matrix

Usage

transformNR(value, rm)

Arguments

value

Numeric value with (n by p) "gradient" and (three dimentional n by p by p) "hessian" attributes. Usually it is right side (predictors) or left side (response) of a nonlinear regression model.

rm

Matrix for transforming. In nonlinear regression if covaraince matrix of error represent by \(\sigma ^2 V\), rm is cholesky decompostion of V.

Value

Transformed values including (n by p) "gradient" and (three dimentional n by p by p) "hessian" attributes.

Details

If errors of a nonlinear regression is Autocorrelated or heteroscedastic, the model can be transformed to uncorrelated and homoscedastic using cholesky decomposition.

  • transformNR: Multiply by rm matrix, create standardized model.

  • transforminv: Multiply by inverse of rm matrix, create heteroscedastic or autocorrelated model.

References

Riazoshams H, Midi H, and Ghilagaber G, 2018,. Robust Nonlinear Regression, with Application using R, Joh Wiley and Sons.

Seber, G., A. F. and Wild, C. J. (2003). Nonlinear Regression. New York: John Wiley & Sons, Inc.

See Also

transforminv

Examples

Run this code
# NOT RUN {
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
"transformNR"
# }

Run the code above in your browser using DataLab