smith-chem-wisc / mzLib

Library for mass spectrometry projects
GNU Lesser General Public License v3.0
26 stars 33 forks source link

Spectrum similarity bug fix #766

Closed trishorts closed 8 months ago

trishorts commented 8 months ago

While creating a method to speed up the spectrum similarity method I discovered a bug where zero intensity pairs were being added even when the bool allPeaks was set to false. This bug made many spectrum similarity calculations poorer than actual.

This PR fixes the bug and fixes unit tests that were incorrect. This PR also adds several comments to improve test readability and understanding.