large-scale regression in R with a sparse feature matrix
I'd like to do large-scale regression (linear/logistic) in R with many (e.g. 100k) features, where each example is relatively sparse in the feature space---e.g., ~1k non-zero features per example. It seems like the SparseM package slm should do this, but I'm having difficulty converting from the sparseMatrix format to a slm -friendly format. I have a numeric vector of labels y and a sparseMatrix of features X \in {0,1}. When I try model <- slm(y ~ X) I get the following error: Error in model.frame.default(formula = y ~ X) : invalid type (S4) for variable 'X' presumably because slm wants a