Repository navigation
Count SPS precursors matching identified peptide fragments in SPS-MS3 - #9706
Merged
Merged
Conversation
Co-authored-by: jpfeuffer <[email protected]>
Copilot
AI
changed the title
[WIP] Add counting of matching MS2 fragments for MS3 scan in IsobaricWorkflow
Count SPS precursors matching identified peptide fragments in SPS-MS3
Jul 3, 2026
Contributor
|
@copilot resolve the merge conflicts in this pull request |
Copilot stopped work on behalf of
timosachsenberg due to an error
July 6, 2026 06:37
timosachsenberg
marked this pull request as ready for review
July 6, 2026 06:50
This was referenced Jul 7, 2026
timosachsenberg
added a commit
that referenced
this pull request
Jul 13, 2026
… (#9731) Backfill CHANGELOG coverage for recently merged PRs that lacked entries: Docker Arrow APT source fix (#9728), TOPPBase external-tool refactor (#9621), cross-reference the SPS precursor-matching feature to its PR (#9706), and note the pyOpenMS binding for addChargeAdduct (#9719). Claude-Session: https://claude.ai/code/session_012umKmTwmgGLGShG6wyQjxQ Co-authored-by: Claude <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
For SPS-MS3 (Synchronous Precursor Selection) experiments, there was no way to estimate how many of the fragments co-isolated for the MS3 reporter scan actually originate from true fragments of the identified peptide — a useful QC metric for reporter-ion quantification.
Changes
PrecursorPurity::countSPSPrecursorsMatchingPeptideFragments()— new static method that generates theoretical b/y fragment m/z for the peptide (viaTheoreticalSpectrumGenerator::getPrefixAndSuffixIonsMZ, sorted) and counts how many of an MS3 spectrum'sPrecursor(SPS) windows match a fragment within tolerance, up tomax_fragment_charge. Matching uses binary search; tolerance supports ppm or Da.IsobaricWorkflow— opt-incount_sps_matchesflag (off by default) plus advancedsps_fragment_mass_tolerance/sps_fragment_mass_tolerance_unitparams. When enabled and MS3 is present, storessps_matched_ionsandsps_precursor_countmeta values per consensus feature. Default output is unchanged. Fragment charge considered is derived from the ID precursor charge (max(1, z-1)).PrecursorPurity_test.cppsection covering empty inputs, matching/non-matching peaks, Da/ppm tolerances, charge handling, and a TSG self-consistency check.API
The counting logic lives in
PrecursorPurity(reusable outside the tool), mirroring the existing precursor-purity approach of iterating a spectrum'sPrecursorlist.