compomics / moFF

A modest Feature Finder (moFF) to extract MS1 intensities from Thermo raw file
Apache License 2.0
33 stars 11 forks source link

Questions about the rt_w and charge #8

Closed fcyu closed 7 years ago

fcyu commented 7 years ago

Hi,

I have two algorithm level questions:

  1. Dose moFF only extract ion intensities with rt_w even though the intensity curve keeps going out of the range of rt_w?
  2. Dose moFF check the charge state given a mz and rt coordinate? Or, is it just blindly extract ion intensity no matter if the charge state is the same as that in the input file?

It will be more than grateful if you can answer these two questions. However, it is totally OK if you don't have time. I will read the source code by myself when I have time.

Thanks

Maux82 commented 7 years ago

Hi,

_Does moFF only extract ion intensities with rt_w even though the intensity curve keeps going out of the range of rtw?

The are two distinct steps in the following order: (1) for each ms2 event in input (rt,mz,charge) moFF extract a XiC of width ± rt_w and centered on rt; (2) moFF tries to find an ion intensity using a smaller rt time window (defined by rt_p; rt ± rt_p) on the XiC data. In the case of matched features, the process is the same but the rt is the predicted rt and not the rt recorded in the ms2 event. For this reason rt_w is always greater than rt_p as default values of the parameters, but there is no control in the code (at least in the current version). If you provide rt_w << rt_p, the apex extraction does not work and it should be raise an exception. I think that a control in the code could avoid possible miss use of moFF thanks to point me this out .

Does moFF check the charge state given a mz and rt coordinate? Or, is it just blindly extract ion intensity no matter if the charge state is the same as that in the input file?

For the apex extraction, moFF does not take into account the charge , but it only takes into account the mz and the rt of the identified features (to extract the XiC see above). Even, in the match-between-run module, moFF matchs the feature in same original charge state of the identified feature at the ms2 event.

I hope that my answers are clear enough , if it is not I will try to explain them better. Thank you for your question

fcyu commented 7 years ago

Hi,

Thanks for your detailed answer.

For the first question, I would like to illustrate with a figure: 307694029068783899 As we can see from the figure, the apex is within rt ± rt_p and it can be located successfully. However, the range of the whole curve is out of the range of rt ± rt_w. The question is: dose moFF includes the red region in extracting ion intensity?

For the second question, your explanation is quite clear. However, I would like give a suggestion: could you add a function to check if the charge state of the extracted ion intensity is the same as that in the input file? If not, may be the extracted ion intensity is incorrect. I think this would increase the accuracy of the results.

Thanks

Maux82 commented 7 years ago

The question is: dose moFF includes the red region in extracting ion intensity? No , moFF includes only the region rt ± rt_w and the red region lies outside.

About the second question, Do you mean to apply this check only for the matched features or for both ? Because for the ms2 feature (input file) moFF uses a mz value that is related to charge state of each identified peptides. Lets assume that the input file looks as: peptide mz mass charge rt EQTEGEYSSLEHESAK 608.603820 1822.789633 3 2355.45 EQTEGEYSSLEHESAK 912.400329 1822.786107 2 2349.90 moFF extracts two different XiC using the two different mz values that depends of the charge state. Can you explain me better your suggestion in this example ?

fcyu commented 7 years ago

Hi,

Thanks for your detailed answer.

For the second question, after finding the apex, moFF may check if the charge state is correct. If not, this means that the found apex does not correspond to the peptide we want. moFF may try to find another apex in the rt_w range (if the rt_w range is quite large). Furthermore, I am using moFF to finish a special task. Each injection of my data contains two mixed samples with two different labelings. I am trying to find pairs of apexes corresponding to one peptide with different labelings. Then compare the ion intensities within each pair. In some situation, Mascot only identifies one of the spectrum in the pair. I have to find another one back based on mz, rt, and charge state. Thus, I list some possible entries in the input file and let moFF to extract them. If moFF could check if the extracted apex's charge state is correct, it would increase the confidence that I find the correct pair of apexes.

I hope my explanation is clear enough.

Thanks

Maux82 commented 7 years ago

Hi, thank you for your explanation. I m agree with your that a charge state control in case of labelled data can be helpful to find the correct pair of peaks In the future we are planning a version of moFF for labelled data where we can also implement the charge state control that you pointed out, but this does not have the highest priority at the moment.

fcyu commented 7 years ago

Thanks a lot.