-
Notifications
You must be signed in to change notification settings - Fork 46
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
Only quantify peptides that clear the q-value threshold #2375
base: master
Are you sure you want to change the base?
Only quantify peptides that clear the q-value threshold #2375
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2375 +/- ##
==========================================
- Coverage 93.65% 93.63% -0.02%
==========================================
Files 140 140
Lines 21898 21916 +18
Branches 3005 3006 +1
==========================================
+ Hits 20508 20522 +14
- Misses 934 937 +3
- Partials 456 457 +1
|
// If peptide level Q-values default to zero, it is hard to determine which PSMs have a legitimate peptide-level Q-value of zero and | ||
// which just weren't included in peptide-level calculations. Hence, we set q values to one here. | ||
psm.PeptideFdrInfo.QValue = 1; | ||
psm.PeptideFdrInfo.PEP_QValue = 1; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we instead default the value to -1 or 1 to make it more clear from instantiation instead of within this method?
@@ -101,6 +101,16 @@ public static void AllResultsAndResultsTxtContainsCorrectValues_PepQValue_Bottom | |||
Assert.AreEqual("TaGe_SA_A549_3_snip_2 - Target protein groups within 1 % FDR: 140", results[15]); | |||
} | |||
|
|||
[Test] | |||
public static void TestPeptideQuantificationResults() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test seems subject to break in the future due to the hard coded number. Could you instead read in the peptides file, count the results at threshold, then use that in your assert?
Previously, when we wrote the AllQuantifiedPeptides output, we filtered based off of PSM q-value. So you would have some peptides with high q-values reported in the quant results. This fixes that!
In order to fix that, I had to reconfigure FDR calculation at the PSM and Peptide level. I did this by adding two new fields to SpectralMatch: PsmFdrInfo and PeptideFdrInfo. The names are self explanatory. There are a variety of toggles that were added to specify when Psm level FDR info should be used and peptide level info should be used.