Repository navigation
XIC: float64 window edge; isotope_trace_evidence span from the strongest trace - #14
Merged
Merged
Conversation
…or its span on the strongest trace Two fixes from the NGlycoM012 feature-level QC review (2026-10-11). - _window_intensity: a SpectrumCache stores m/z as float32, and `float32_array - python_float` stays float32 under NumPy's promotion rules, so the TARGET was rounded to float32 before the subtraction (about 0.06 ppm at m/z 1000) and a peak at the window edge could fall inside on an mzML and outside on the cache built from it. The edge is now tested in float64. Test: a sweep of targets over a float32 array must equal a float64 reference, and the float32 path must have disagreed somewhere in the sweep for the test to count. - isotope_trace_evidence(span_from='mono' | 'strongest'): the half-maximum span the per-isotope intensities are summed over came from the M trace alone, so a large glycopeptide whose monoisotopic peak sits at the noise floor while M+1 and M+2 are clear yielded an empty span and read as absent rather than as a weak monoisotope. 'strongest' anchors on the tallest isotope trace and records it as span_trace; co-elution is then measured against that trace, so a lighter species one neutron below is still flagged when the assigned M is missing (the one-neutron-too-heavy case). Default 'mono' is unchanged: identical span, co-elution and m_minus_1 arithmetic, pinned by the existing tests. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
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.
XIC: float64 window edge; isotope_trace_evidence span from the strongest trace