Description Usage Arguments Details Value
Calculates the MLE of the coefficients of the usual linear regression model (LM).
1 | lm_fit(y, X, w)
|
y |
Vector of observations of length |
X |
Mean covariate matrix of size |
w |
Optional positive weights vector of length |
The LM model is defined as
y_i | x_i ~ind N(x_i'β, 1/w_i),
where for each subject i, y_i is the response, x_i \in R^p is the mean covariate vector, and w_i is an optional positive weight (defaults to 1).
Warning: This R wrapper function provides a direct interface to the C++ source code. Incorrect argument specification may lead to abrupt termination of the R session.
MLE estimate of beta
as a vector of length p
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.