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

Update cluster_logfc.R and wmw_gsea.R for compatibility with R>=4.0.0 #4

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

svigneau
Copy link

Updated cluster_logfc.R and wmw_gsea.R for compatibility with R >4.0.0. Since R 4.0.0, matrices have two classes, "matrix" and "array", which leads to a "condition has length > 1" error when running, e.g., if (!class(expr.mat)=="dgCMatrix"). The "inherits" or "is" functions should be used instead of "==" for checking the class (https://developer.r-project.org/Blog/public/2019/11/09/when-you-think-class.-think-again/index.html).
@svigneau

Updated for compatibility with R >4.0.0. Since R 4.0.0, matrices have two classes, "matrix" and "array", which leads to a "condition has length > 1" error when running `if (!class(expr.mat)=="dgCMatrix")`. The "inherits" or "is" functions should be used instead of "==" for checking the class (https://developer.r-project.org/Blog/public/2019/11/09/when-you-think-class.-think-again/index.html).
Updated for compatibility with R >4.0.0. Since R 4.0.0, matrices have two classes, "matrix" and "array", which leads to a "condition has length > 1" error when running `if (!class(expr.mat)=="matrix")`. The "inherits" or "is" functions should be used instead of "==" for checking the class (https://developer.r-project.org/Blog/public/2019/11/09/when-you-think-class.-think-again/index.html).
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

Successfully merging this pull request may close these issues.

1 participant