/usr/lib/R/site-library/SparseM/TODO is in r-cran-sparsem 1.74-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | March 30 2014
Use of slm it is sometimes impeded by the fact that model.matrix
require a construction of a dense form of X. This can be circumvented
by using the sparse model matrix construction in the Matrix package, or
less directly by just constructing X in csr form and using slm.fit.csr
for estimation. A downside of the latter strategy is that summary()
can't be used on the resulting object, but something like the following
hack can be used:
function (object, correlation = FALSE, ...)
{
Chol <- object$chol
n <- length(object$residuals)
p <- object$chol@nrow
rdf <- n - p
r <- residuals(object)
rss <- sum(r^2)
resvar <- rss/rdf
R <- backsolve(Chol, diag(p))
sqrt(diag(R) * resvar)
}
It might be nice to regularize this...
|