-
Notifications
You must be signed in to change notification settings - Fork 370
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sparse Model.Matrix #614
Comments
I'd love to provide methods for doing this. It should be a separate function to maintain type-stability of the output. The only thing that could be seen as blocking this is the generally weak state of the Formula interface these days. Since we're no longer eval-ing things, we need a formal definition of what Formula means. |
Has this situation evolved in the past few years? This is something I'd be very interested in and would be happy to help contribute to. |
I don't think anybody has worked on it, but we'd be happy to help you if you want to make a pull request. |
As for the implementation/interface, I guess we should just make the |
Ok, thanks, I'll take a look and come back with any questions. |
OK, so if I'm understanding things properly, what would need to be done is:
With that, |
Actually, I would be a shame to base your work on the current code while there's a large rework in the tubes at #870. Better base your work on that PR. You should look at the
I think you can keep
I guess so. Though the current code is quite inefficient even for dense matrices, see https://github.com/JuliaStats/DataFrames.jl/pull/870/files#r62338400. Since using sparse matrices is all about performance and memory use, you may want to give more attention to the way you concatenate columns to create the matrix. |
Thanks, that's exactly the kind of feedback I was looking for! I'll check out #870. |
@GordStephen Should this be closed now? |
Are there any plans to make Model.Matrix return a Sparse matrix? Something similar to
sparse.model.matrix
implemented in the R packageMatrix
written by @dmbates. I wanted to give it a try, but I wanted to know first whether there are issues blocking such an attempt.The text was updated successfully, but these errors were encountered: