| OpenMS 2.5.0

Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
RTSimulation Class Reference
Simulation

Simulates/Predicts retention times for peptides or peptide separation. More...

`#include <OpenMS/SIMULATION/RTSimulation.h>`

Inheritance diagram for RTSimulation:

## Public Member Functions

RTSimulation & | operator= (const RTSimulation &source)
| Assignment operator. More...
void | predictRT (SimTypes::FeatureMapSim &features)
| Predict retention times for given peptide features based for HPLC or CE. More...
void | predictContaminantsRT (SimTypes::FeatureMapSim &)
| Set retention times randomly for given contaminants. More...
bool | isRTColumnOn () const
| Returns true if a RT column was simulated. More...
void | wrapSVM (std::vector< AASequence > &peptide_sequences, std::vector< double > &predicted_retention_times)
| Wrapper for the SVM RT Prediction (HPLC) using AASequences. More...
SimTypes::SimCoordinateType | getGradientTime () const
void | createExperiment (SimTypes::MSSimExperiment &experiment)
| Size experiment and assign retention time grid. More...
Constructors and Destructors
| RTSimulation ()
| Default constructor. More...
| RTSimulation (SimTypes::MutableSimRandomNumberGeneratorPtr random_generator)
| Constructor taking a random generator. More...
| RTSimulation (const RTSimulation &source)
| Copy constructor. More...
| ~RTSimulation () override
| Destructor. 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...
virtual DefaultParamHandler & | operator= (const DefaultParamHandler &rhs)
| Assignment operator. More...
virtual bool | operator== (const DefaultParamHandler &rhs) const
| Equality operator. More...
void | setParameters (const Param &param)
| 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
| Synchronize members with param class. More...
Protected Member Functions inherited from DefaultParamHandler
void | defaultsToParam_ ()
| Updates the parameters after the defaults have been set in the constructor. More...

## Protected Attributes

SimTypes::MutableSimRandomNumberGeneratorPtr | rnd_gen_
| Random number generator. 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...

## Private Member Functions

void | setDefaultParams_ ()
| Set default parameters. More...
void | noRTColumn_ (SimTypes::FeatureMapSim &)
| Simply set all retention times to -1. More...
void | smoothRTDistortion_ (SimTypes::MSSimExperiment &experiment)
| smoothes the simulated distortion for the elution profiles with a moving average filter of size 3 More...
void | calculateMT_ (SimTypes::FeatureMapSim &features, std::vector< double > &predicted_retention_times)
void | getChargeContribution_ (Map< String, double > &q_cterm, Map< String, double > &q_nterm, Map< String, double > &q_aa_basic, Map< String, double > &q_aa_acidic)

## Private Attributes

OpenMS::String | rt_model_file_
SimTypes::SimCoordinateType | total_gradient_time_
| Total gradient time. More...
SimTypes::SimCoordinateType | gradient_min_
| gradient ranges More...
SimTypes::SimCoordinateType | gradient_max_
| Maximal observed gradient time. More...
SimTypes::SimCoordinateType | rt_sampling_rate_
| bin size in rt dimension More...
double | egh_tau_location_
| EGH tau value. More...
double | egh_tau_scale_
| EGH tau scale parameter of the lorentzian variation. More...
double | egh_variance_location_
| EGH sigma value. More...
double | egh_variance_scale_
| EGH sigma scale parameter of the lorentzian variation. More...

## Detailed Description

Simulates/Predicts retention times for peptides or peptide separation.

The retention times for the different peptides are determined based on a SVM model or are all set to -1 in case of simulations without a HPLC column.

Parameters of this class are:

Name | Type | Default | Restrictions | Description
--- | --- | --- | --- | ---
rt_column | string | HPLC | none, HPLC, CE | Modelling of an RT or CE column
auto_scale | string | true | true, false | Scale predicted RT's/MT's to given 'total_gradient_time'? If 'true', for CE this means that 'CE:lenght_d', 'CE:length_total', 'CE:voltage' have no influence.
total_gradient_time | float | 2500.0 | min: 1.0e-05 | The duration [s] of the gradient.
sampling_rate | float | 2.0 | min: 0.01 max: 60.0 | Time interval [s] between consecutive scans
scan_window:min | float | 500.0 | min: 0.0 | Start of RT Scan Window [s]
scan_window:max | float | 1500.0 | min: 1.0 | End of RT Scan Window [s]
variation:feature_stddev | int | 3 |  | Standard deviation of shift in retention time [s] from predicted model (applied to every single feature independently)
variation:affine_offset | int | 0 |  | Global offset in retention time [s] from predicted model
variation:affine_scale | int | 1 |  | Global scaling in retention time from predicted model
column_condition:distortion | int | 0 | min: 0 max: 10 | Distortion of the elution profiles. Good presets are 0 for a perfect elution profile, 1 for a slightly distorted elution profile etc... For trapping instruments (e.g. Orbitrap) distortion should be >4.
profile_shape:width:value | float | 9.0 | min: 0.0 | Width of the Exponential Gaussian Hybrid distribution shape of the elution profile. This does not correspond directly to the width in [s].
profile_shape:width:variance | float | 1.6 | min: 0.0 | Random component of the width (set to 0 to disable randomness), i.e. scale parameter for the lorentzian variation of the variance (Note: The scale parameter has to be >= 0).
profile_shape:skewness:value | float | 0.1 |  | Asymmetric component of the EGH. Higher absolute(!) values lead to more skewness (negative values cause fronting, positive values cause tailing). Tau parameter of the EGH, i.e. time constant of the exponential decay of the Exponential Gaussian Hybrid distribution shape of the elution profile.
profile_shape:skewness:variance | float | 0.3 | min: 0.0 | Random component of skewness (set to 0 to disable randomness), i.e. scale parameter for the lorentzian variation of the time constant (Note: The scale parameter has to be > 0).
HPLC:model_file | string | examples/simulation/RTPredict.model |  | SVM model for retention time prediction
CE:pH | float | 3.0 | min: 0.0 max: 14.0 | pH of buffer
CE:alpha | float | 0.5 | min: 0.0 max: 1.0 | Exponent Alpha used to calculate mobility
CE:mu_eo | float | 0.0 | min: 0.0 max: 5.0 | Electroosmotic flow
CE:lenght_d | float | 70.0 | min: 0.0 max: 1000.0 | Length of capillary [cm] from injection site to MS
CE:length_total | float | 75.0 | min: 0.0 max: 1000.0 | Total length of capillary [cm]
CE:voltage | float | 1000.0 | min: 0.0 | Voltage applied to capillary

Note:

- If a section name is documented, the documentation is displayed as tooltip.
- Advanced parameter names are italic.

## Constructor & Destructor Documentation

## ◆ RTSimulation() [1/3]

RTSimulation | ( |  | ) |

Default constructor.

## ◆ RTSimulation() [2/3]

RTSimulation | ( | SimTypes::MutableSimRandomNumberGeneratorPtr | random_generator | ) |

explicit

Constructor taking a random generator.

## ◆ RTSimulation() [3/3]

RTSimulation | ( | const RTSimulation & | source | ) |

Copy constructor.

## ◆ ~RTSimulation()

~RTSimulation | ( |  | ) |

override

Destructor.

## Member Function Documentation

## ◆ calculateMT_()

void calculateMT_ | ( | SimTypes::FeatureMapSim & | features,
|  | std::vector< double > & | predicted_retention_times
| ) |  |

private

Wrapper for the Migration time calculation (CE)

Parameters

  features | will get modified with metavalue "RT_CE_width_factor", describing widening of MT shape.
  predicted_retention_times | will contain afterwards the predicted retention times.

## ◆ createExperiment()

void createExperiment | ( | SimTypes::MSSimExperiment & | experiment | ) |

Size experiment and assign retention time grid.

## ◆ getChargeContribution_()

void getChargeContribution_ | ( | Map< String, double > & | q_cterm,
|  | Map< String, double > & | q_nterm,
|  | Map< String, double > & | q_aa_basic,
|  | Map< String, double > & | q_aa_acidic
| ) |  |

private

## ◆ getGradientTime()

SimTypes::SimCoordinateType getGradientTime | ( |  | ) | const

## ◆ isRTColumnOn()

bool isRTColumnOn | ( |  | ) | const

Returns true if a RT column was simulated.

## ◆ noRTColumn_()

void noRTColumn_ | ( | SimTypes::FeatureMapSim & |  | ) |

private

Simply set all retention times to -1.

## ◆ operator=()

RTSimulation& operator= | ( | const RTSimulation & | source | ) |

Assignment operator.

## ◆ predictContaminantsRT()

void predictContaminantsRT | ( | SimTypes::FeatureMapSim & |  | ) |

Set retention times randomly for given contaminants.

## ◆ predictRT()

void predictRT | ( | SimTypes::FeatureMapSim & | features | ) |

Predict retention times for given peptide features based for HPLC or CE.

Parameters

  features | Feature map for which the retention times will be predicted

## ◆ setDefaultParams_()

void setDefaultParams_ | ( |  | ) |

private

Set default parameters.

## ◆ smoothRTDistortion_()

void smoothRTDistortion_ | ( | SimTypes::MSSimExperiment & | experiment | ) |

private

smoothes the simulated distortion for the elution profiles with a moving average filter of size 3

## ◆ updateMembers_()

void updateMembers_ | ( |  | ) |

override protected virtual

Synchronize members with param class.

Reimplemented from DefaultParamHandler.

## ◆ wrapSVM()

void wrapSVM | ( | std::vector< AASequence > & | peptide_sequences,
|  | std::vector< double > & | predicted_retention_times
| ) |  |

Wrapper for the SVM RT Prediction (HPLC) using AASequences.

## Member Data Documentation

## ◆ egh_tau_location_

double egh_tau_location_

private

EGH tau value.

## ◆ egh_tau_scale_

double egh_tau_scale_

private

EGH tau scale parameter of the lorentzian variation.

## ◆ egh_variance_location_

double egh_variance_location_

private

EGH sigma value.

## ◆ egh_variance_scale_

double egh_variance_scale_

private

EGH sigma scale parameter of the lorentzian variation.

## ◆ gradient_max_

SimTypes::SimCoordinateType gradient_max_

private

Maximal observed gradient time.

## ◆ gradient_min_

SimTypes::SimCoordinateType gradient_min_

private

gradient ranges

Minimal observed gradient time

## ◆ rnd_gen_

SimTypes::MutableSimRandomNumberGeneratorPtr rnd_gen_

protected

Random number generator.

## ◆ rt_model_file_

OpenMS::String rt_model_file_

private

## ◆ rt_sampling_rate_

SimTypes::SimCoordinateType rt_sampling_rate_

private

bin size in rt dimension

## ◆ total_gradient_time_

SimTypes::SimCoordinateType total_gradient_time_

private

Total gradient time.