Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement conversion fcts from R's Spectra to Python's spectrum_utils #47

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

tnaake
Copy link
Contributor

@tnaake tnaake commented Feb 6, 2025

The PR introduces functions to convert from R'/Spectra's Spectra object to Python'/spectrum_utils's MsmsSpectrum class, as well as some refactoring that the functions can work on both matchms and spectrum_utils, specified by the pythonLibrary argument. I have added tests to test the correct behaviour of the code.

As discussed there is a loss of information of a Spectra object when converting to MsmsSpectrum and back:

  • loss of precision in m/z values
  • msLevel is not supported in MsmsSpectrum.

I am happy to discuss how we can circumvent the latter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants