Repository navigation
Mark the precursor m/z on the PSM spectrum - #180
Open
t0mdavid-m wants to merge 1 commit into
Open
t0mdavid-m wants to merge 1 commit into
t0mdavid-m wants to merge 1 commit into
Conversation
The annotated spectrum of a picked PSM draws a dotted guide at the
precursor m/z, labelled with its charge ("precursor 2+"), when the
installed openms-insight LinePlot takes x_markers; older builds show
the spectrum as before.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01D5Wo2FHPpi5a8X6GppNxEk
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
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.
Before: the annotated spectrum of a picked PSM showed its fragments, but nothing showed where the precursor sits. To check for a co-isolated peak or a leftover precursor near the fragments, you had to read the m/z off the PSM table.
After: the spectrum draws a dotted guide at the precursor m/z, labelled with its charge (for example "precursor 3+"). It is there in the Identification view and in the spectrum below the database search and filtered PSM tables, and it follows the PSM you pick.
The marker uses the
x_markersoption of the openms-insight LinePlot (0.7.6). An older openms-insight leaves the option out, and the spectrum looks as before (precursor_markerchecks what the installed component takes, asprecursor_windowalready does). The spectrum mirrored against the prediction also passes the marker. It appears there once MirrorPlot takesx_markers.How:
src/common/precursor_window.pygetsprecursor_marker(mz, charge, component).show_spectrumtakesprecursor_mz, and both callers pass the PSM's m/z. Tests intests/test_precursor_window.pycover the label, the missing or non-positive m/z, and a component without the option.pytest test_gui.py tests/passes (1349 passed, 6 skipped), and pylint--errors-onlyis clean.Screenshots
Picking other PSMs moves the guide (mp4):
Generated by Claude Code