Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/MSDIAL5/MsdialCore/Parameter/ParameterBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1148,7 +1148,7 @@ public class AlignmentBaseParameter {
[Key(3)]
public float SpectrumSimilarityAlignmentFactor { get; set; } = 0.5F;
[Key(4)]
public float Ms1AlignmentTolerance { get; set; } = 0.015F;
public float Ms1AlignmentTolerance { get; set; } = 0.5F;
[Key(5)]
public float RetentionTimeAlignmentTolerance { get; set; } = 0.10F;
[Key(6)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ protected GcmsPeakJoiner(AlignmentIndexType indextype, RiCompoundType riCompound
_comparer = comparer;
_alignmentParameter = parameter.AlignmentBaseParam;
_riCompoundType = riCompoundType;
_msMatchParam = msMatchParam;
_msMatchParam = new MsRefSearchParameterBase() { Ms1Tolerance = 0.5F, Ms2Tolerance = 0.5F, MassRangeBegin = 0, MassRangeEnd = 2000 };
Copy link

Copilot AI Feb 23, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The constructor ignores the provided msMatchParam argument and always replaces it with a new MsRefSearchParameterBase. This makes CreateRTJoiner/CreateRIJoiner's msMatchParam parameter ineffective and prevents callers from configuring spectrum matching behavior. Use the passed-in parameter (or a copy of it) and only override specific fields if needed.

Suggested change
_msMatchParam = new MsRefSearchParameterBase() { Ms1Tolerance = 0.5F, Ms2Tolerance = 0.5F, MassRangeBegin = 0, MassRangeEnd = 2000 };
_msMatchParam = msMatchParam ?? new MsRefSearchParameterBase() { Ms1Tolerance = 0.5F, Ms2Tolerance = 0.5F, MassRangeBegin = 0, MassRangeEnd = 2000 };

Copilot uses AI. Check for mistakes.
_parameter = parameter;
_evaluator = evaluator;
_refer = refer;
Expand Down
Loading