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

do_groupChromPeaks_nearest does not accept data frame #359

Closed
DWgit opened this issue Mar 14, 2019 · 4 comments
Closed

do_groupChromPeaks_nearest does not accept data frame #359

DWgit opened this issue Mar 14, 2019 · 4 comments

Comments

@DWgit
Copy link

DWgit commented Mar 14, 2019

The doc for do_groupChromPeaks_nearest says

peaks: A ‘matrix’ or ‘data.frame’ with the mz values and retention ...

but the type-checking code in do_groupChromPeaks-functions.R is:

   if (!is.matrix(peaks) | is.data.frame(peaks))
        stop("Peaks has to be a 'matrix' or a 'data.frame'!")

The ! operator has higher precedence than |, so a data frame hits the stop. An obvious fix is to add parens if (! (... | ...))

@jorainer
Copy link
Collaborator

Good point! I'll fix.

jorainer added a commit that referenced this issue Mar 15, 2019
- Support also a peaks data.frame in do_groupChromPeaks_...
jorainer added a commit that referenced this issue Mar 15, 2019
@jorainer
Copy link
Collaborator

It is fixed in the current developmental version (master branch) and also in the branch matching the version from Bioconductor version 3.8. To install the latter:

devtools::install_github("sneumann/xcms", ref = "RELEASE_3_8")

@DWgit
Copy link
Author

DWgit commented Mar 15, 2019

Thanks for the speedy fix!

@jorainer
Copy link
Collaborator

I'm closing the issue now. Feel free to re-open if needed.

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