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

correction charge in mzML file #435

Open
1 of 4 tasks
neel-lab opened this issue May 28, 2024 · 2 comments
Open
1 of 4 tasks

correction charge in mzML file #435

neel-lab opened this issue May 28, 2024 · 2 comments

Comments

@neel-lab
Copy link

What is the type of your request?

  • Incomplete / missing
  • Typo
  • Unclear
  • Not reproducible

Include a description of your report

I am trying to use PrecursorCorrection function to correct for unassigned charge in my .raw file that is now converted to mzML using preoteowizard. I followed documentation at https://pyopenms.readthedocs.io/en/latest/apidocs/_autosummary/pyopenms/pyopenms.PrecursorCorrection.html

Here is the code I used:
pc = oms.PrecursorCorrection()
corrected_indices = pc.correctToNearestFeature(oms.FeatureMap(), centroided_exp, rt_tolerance_s=0, mz_tolerance=5,
ppm=True, believe_charge=False, keep_original=False, all_matching_features=False, max_trace=2, debug_level=0)

I basically set believe_charge to False, and guessed what the other parameter values may be as there was no example in the documentation. The code runs without error but it does not rectify errors that exist in the original .raw file. Can you please provide a suggestion on what maybe my error. Thanks!

@jpfeuffer
Copy link
Contributor

Hi!

I think the confusion comes from the fact that this type of precursor correction uses isotopic trace information of complete MS1 features. For this to work, you actually have to fill the FeatureMap first (i.e. Run one of the feature finders on it first).

I am not sure if we currently have an MS1-agnostic corrector @timosachsenberg

@timosachsenberg
Copy link
Contributor

MSConvert features a simple charge state predictor algorithm that can be added as a filter for unassigned precursor charges:
image

Might be worth a try.

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

No branches or pull requests

3 participants