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

removing non-proteotypic peptide #585

Open
ibphuangchen opened this issue Nov 17, 2022 · 0 comments
Open

removing non-proteotypic peptide #585

ibphuangchen opened this issue Nov 17, 2022 · 0 comments

Comments

@ibphuangchen
Copy link

ibphuangchen commented Nov 17, 2022

Hi @lgatto ,

I felt that the code used to remove non-proteotypic peptide might not work as expected:

keep <- tapply(x[, accession], x[, spectrumID], function(xx) length(unique(xx))) == 1
x <- x[keep, ]
n3 <- nrow(x)

I found this out when I was debugging my issues. length(keep) might not be the same with nrow(x). Probably what you mean is:

keep <- tapply(x[, accession], x[, spectrumID], function(xx) length(unique(xx))) == 1
x <- x[x[,spectrumID] %in% names(keep)[keep],]
n3 <- nrow(x)

Is that right?

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

1 participant