| gpuLm.fit | R Documentation |
The C code called by this function was written by
Mark Seligman at Rapid Biologics, http://rapidbiologics.com
The function gpuLm calls this function
to fit linear models. So gpuLm.fit should not need to be used
directly.
gpuLm.fit(x, y, w = NULL, offset = NULL, method = "qr",
useSingle = getOption("gputools.precision", "single") == "single",
tol = gpuLm.defaultTol(useSingle), singular.ok = TRUE, ...)
x |
design matrix of dimension |
y |
vector of observations of length |
w |
vector of weights (length |
offset |
numeric of length |
method |
currently, only |
useSingle |
logical: |
tol |
tolerance for the |
singular.ok |
logical. If |
... |
currently disregarded. |
a list with components
coefficients |
|
residuals |
|
fitted.values |
|
effects |
(not null fits) |
weights |
|
rank |
integer, giving the rank |
df.residual |
degrees of freedom of residuals |
qr |
(not null fits) the QR decomposition, see |
gpuLm which should usually be used for linear least squares
regression
require(utils)
set.seed(129)
n <- 7 ; p <- 2
X <- matrix(rnorm(n * p), n,p) # no intercept!
y <- rnorm(n)
w <- rnorm(n)^2
str(lmw <- gpuLm.fit(x=X, y=y, w=w))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.