I did not find a function to calculate orthogonal regression (TLS - Total Least Squares).
Is there a package with this feature?
Update: I mean, calculate the distance of each point symmetrically and asymmetrically, like lm().
lm()
You might want to consider a function Deming()in the MethComp package [ function information ]. The package also contains a detailed derivation of the theory behind Deming's regression.
Deming()
The following R-archive search also provides many options:
CrossValidated, R-Help , , , , " " " " .
:
gx.rma
rgr
URL:
https://www.inkling.com/read/r-cookbook-paul-teetor-1st/chapter-13/recipe-13-5
r <- prcomp( ~ x + y ) slope <- r$rotation[2,1] / r$rotation[1,1] intercept <- r$center[2] - slope*r$center[1]
PCA, x y, . .
, , "onls", .
, , "onls". nls ( )