lsfit(x, y, wt, intercept=TRUE, tolerance=1e-07, yname=NULL)
x
| a matrix whose rows correspond to cases and whose columns correspond to variables. |
y
| the responses, possibly matrix valued if you want to fit multiple left hand sides. |
wt
| an optional vector of weights for performing weighted least squares. |
intercept
| whether or not an intercept term should be used. |
tolerance
| the tolerance to be used in the matrix decomposition. |
yname
| an unused parameter for compatibility. |
y = X beta + epsilon
wt
.
If any observation has a missing value in any field, that observation is removed before the analysis is carried out. This can be quite inefficient if there is a lot of missing data.
The implementation is via a modification of the LINPACK subroutines which allow for multiple left-hand sides.
coef
residuals
intercept
qr
ls.diag
, rreg
.