OpenMS
|
Data processing for FIA-MS data. More...
#include <OpenMS/ANALYSIS/ID/FIAMSDataProcessor.h>
Public Member Functions | |
FIAMSDataProcessor () | |
Constructor. More... | |
~FIAMSDataProcessor () override=default | |
Default destructor. More... | |
FIAMSDataProcessor (const FIAMSDataProcessor &cp)=default | |
Copy constructor. More... | |
FIAMSDataProcessor & | operator= (const FIAMSDataProcessor &fdp)=default |
Assignment. More... | |
bool | run (const MSExperiment &experiment, const float n_seconds, OpenMS::MzTab &output, const bool load_cached_spectrum=true) |
Run the full analysis for the experiment for the given time interval. More... | |
void | cutForTime (const MSExperiment &experiment, const float n_seconds, std::vector< MSSpectrum > &output) |
Cut the time axis of the experiment from 0 to n_seconds . More... | |
MSSpectrum | mergeAlongTime (const std::vector< OpenMS::MSSpectrum > &input) |
Sum the spectra with different retention times into one. More... | |
MSSpectrum | extractPeaks (const MSSpectrum &input) |
Pick peaks from the summed spectrum. More... | |
FeatureMap | convertToFeatureMap (const MSSpectrum &input) |
Convert a spectrum to a feature map with the corresponding polarity. More... | |
MSSpectrum | trackNoise (const MSSpectrum &input) |
Estimate noise for each peak. More... | |
void | runAccurateMassSearch (FeatureMap &input, OpenMS::MzTab &output) |
Perform accurate mass search. More... | |
const std::vector< float > & | getMZs () |
Get mass-to-charge ratios to base the summing the spectra along the time axis upon. More... | |
const std::vector< float > & | getBinSizes () |
Get the sliding bin sizes for summing the spectra along the time axis. More... | |
Public Member Functions inherited from DefaultParamHandler | |
DefaultParamHandler (const String &name) | |
Constructor with name that is displayed in error messages. More... | |
DefaultParamHandler (const DefaultParamHandler &rhs) | |
Copy constructor. More... | |
virtual | ~DefaultParamHandler () |
Destructor. More... | |
DefaultParamHandler & | operator= (const DefaultParamHandler &rhs) |
Assignment operator. More... | |
virtual bool | operator== (const DefaultParamHandler &rhs) const |
Equality operator. More... | |
void | setParameters (const Param ¶m) |
Sets the parameters. More... | |
const Param & | getParameters () const |
Non-mutable access to the parameters. More... | |
const Param & | getDefaults () const |
Non-mutable access to the default parameters. More... | |
const String & | getName () const |
Non-mutable access to the name. More... | |
void | setName (const String &name) |
Mutable access to the name. More... | |
const std::vector< String > & | getSubsections () const |
Non-mutable access to the registered subsections. More... | |
Protected Member Functions | |
void | updateMembers_ () override |
This method is used to update extra member variables at the end of the setParameters() method. More... | |
Protected Member Functions inherited from DefaultParamHandler | |
void | defaultsToParam_ () |
Updates the parameters after the defaults have been set in the constructor. More... | |
Private Member Functions | |
void | storeSpectrum_ (const MSSpectrum &input, const String &filename) |
Store the spectrum to the given filepath. More... | |
Private Attributes | |
std::vector< float > | mzs_ |
std::vector< float > | bin_sizes_ |
SavitzkyGolayFilter | sgfilter_ |
PeakPickerHiRes | picker_ |
Additional Inherited Members | |
Static Public Member Functions inherited from DefaultParamHandler | |
static void | writeParametersToMetaValues (const Param &write_this, MetaInfoInterface &write_here, const String &key_prefix="") |
Writes all parameters to meta values. More... | |
Protected Attributes inherited from DefaultParamHandler | |
Param | param_ |
Container for current parameters. More... | |
Param | defaults_ |
Container for default parameters. This member should be filled in the constructor of derived classes! More... | |
std::vector< String > | subsections_ |
Container for registered subsections. This member should be filled in the constructor of derived classes! More... | |
String | error_name_ |
Name that is displayed in error messages during the parameter checking. More... | |
bool | check_defaults_ |
If this member is set to false no checking if parameters in done;. More... | |
bool | warn_empty_defaults_ |
If this member is set to false no warning is emitted when defaults are empty;. More... | |
Data processing for FIA-MS data.
Flow injection analysis (FIA) omits the separation step by removal of the column. It allows for much faster processing time with the cost of ambiguities in the data interpretation. The compounds are identified through the accurate mass search.
Flow injection analysis class implements the basic FIA-MS data processing steps such as: acquiring the data for the certain time interval, summing along the time axis, smoothing the peaks, peak picking and accurate mass search. The batch runs are to be managed with the FIAMSSchedule class that takes a simple csv file as an input.
The workflow is inspired by the data processing from Fuhrer et al https://pubs.acs.org/doi/10.1021/ac201267k though it is not the exact implementation.
Constructor.
|
overridedefault |
Default destructor.
|
default |
Copy constructor.
FeatureMap convertToFeatureMap | ( | const MSSpectrum & | input | ) |
Convert a spectrum to a feature map with the corresponding polarity.
Applies SavitzkyGolayFilter
and PeakPickerHiRes
input | Input a picked spectrum |
void cutForTime | ( | const MSExperiment & | experiment, |
const float | n_seconds, | ||
std::vector< MSSpectrum > & | output | ||
) |
Cut the time axis of the experiment from 0 to n_seconds
.
experiment | Input MSExperiment |
n_seconds | Input number of seconds |
output | [out] Spectra with retention time less than n_seconds |
MSSpectrum extractPeaks | ( | const MSSpectrum & | input | ) |
Pick peaks from the summed spectrum.
input | Input vector of spectra |
const std::vector<float>& getBinSizes | ( | ) |
Get the sliding bin sizes for summing the spectra along the time axis.
const std::vector<float>& getMZs | ( | ) |
Get mass-to-charge ratios to base the summing the spectra along the time axis upon.
MSSpectrum mergeAlongTime | ( | const std::vector< OpenMS::MSSpectrum > & | input | ) |
Sum the spectra with different retention times into one.
The bin size for summing the intensities is defined as mz / (resolution*4) for all the mzs taken with the bin_step
defined in the parameters. Uses SpectrumAddition::addUpSpectra
function with the sliding bin size parameter.
input | Input vector of spectra |
|
default |
Assignment.
bool run | ( | const MSExperiment & | experiment, |
const float | n_seconds, | ||
OpenMS::MzTab & | output, | ||
const bool | load_cached_spectrum = true |
||
) |
Run the full analysis for the experiment for the given time interval.
The workflow steps are:
The intermediate summed spectra and picked peaks can be saved to the filesystem. Also, the results of the accurate mass search and the signal-to-noise information of the resulting spectrum is saved.
experiment | Input MSExperiment | |
n_seconds | Input number of seconds | |
load_cached_spectrum | Load the cached picked spectrum if exists | |
[out] | output | Output of the accurate mass search results |
void runAccurateMassSearch | ( | FeatureMap & | input, |
OpenMS::MzTab & | output | ||
) |
Perform accurate mass search.
input | Input a feature map |
output | [out] mzTab file with the accurate mass search results |
|
private |
Store the spectrum to the given filepath.
MSSpectrum trackNoise | ( | const MSSpectrum & | input | ) |
Estimate noise for each peak.
Uses SignalToNoiseEstimatorMedianRapid
input | Input a picked spectrum |
|
overrideprotectedvirtual |
This method is used to update extra member variables at the end of the setParameters() method.
Also call it at the end of the derived classes' copy constructor and assignment operator.
The default implementation is empty.
Reimplemented from DefaultParamHandler.
|
private |
|
private |
|
private |
|
private |