Skip to content
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 matrix error #47

Open
grayskripko opened this issue Nov 26, 2019 · 2 comments
Open

Sparse matrix error #47

grayskripko opened this issue Nov 26, 2019 · 2 comments

Comments

@grayskripko
Copy link

I find it misleading trying to use embed() on a sparse matrix and don't get an error. After an investigation, I see a call of as.matrix() on my sparse matrix. I think it's reasonable to throw an error preventing a memory explosion. Even more, the call as.matrix() assumes a user can pass something else and the result can be unexpected. It's dangerous and in some point of view, in most cases, useless.

@gdkrmr
Copy link
Owner

gdkrmr commented Nov 26, 2019

That's the R philosophy :-), there is lots of code that does so. Also "dangerous" is a strong word, if you deal with medium size data in R you have to be aware of your memory footprint anyway.

Fun aside, thanks for reporting this, you are right and it makes sense to allow only matrices as input, still this is a code change that is breaking breaking and has to be considered carefully.

@grayskripko
Copy link
Author

tidyverse works with it using warnings()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants