- Notifications
You must be signed in to change notification settings - Fork55
Description
Currently, it is mandatory to load package Matrix if someone get sparse matrix in parameter or turn it back to R environment. I proposed a patch (pr#192) that was supposed to circumvent an obligation to do so but Matrix is still needed. I would like to propose another one that will finally allow to avoid an obligation to load Matrix.
With this new path, a user function can take a simple_triplet_matrix type as argument and (to go in opposite direction) use a function
List simple_triplet_matrix(const arma::SpMat<T> &)to be able to return a sparse matrix without requiring S4 classes defined in Matrix package.
The motivation behind all of this is that a user needing only lightweight operations on sparse matrices should have an opportunity to pass by lightweight packages. Unfortunately, Matrix can require more than 1 s to load which can be prohibitive for programs intended to run in very short time.