Matrix Science header
Public Member Functions

ms_peptide_quant_ratio Class Reference
[Quantitation analysis for Mascot Server and Distiller]

Peptide abundance in one component relative to another in a quantitation experiment. More...

#include <ms_peptide_quant_ratio.hpp>

Collaboration diagram for ms_peptide_quant_ratio:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ms_peptide_quant_ratio (const ms_peptide_quant_key &key, const std::string &ratioName, bool isInfinite=false)
 Default constructor: create an infinite or undefined ("missing") peptide ratio associated with a particular peptide quant key and a ratio name.
 ms_peptide_quant_ratio (const ms_peptide_quant_key &key, const std::string &ratioName, double value, bool isExcluded=false, double weight=1.0)
 Create a peptide ratio associated with a particular peptide quant key and ratio name.
 ms_peptide_quant_ratio (const ms_peptide_quant_ratio &src)
 Copying constructor.
 ~ms_peptide_quant_ratio ()
 Destructor.
void copyFrom (const ms_peptide_quant_ratio *src)
 Copies all content from another instance of the class.
ms_peptide_quant_key getKey () const
 Return the peptide quant key associated with this peptide ratio.
std::string getRatioName () const
 Return the name of the peptide ratio.
double getValue () const
 Return the numerical value of the ratio.
double getWeight () const
 Return the weighting factor of the peptide ratio, or 1.0 if not set.
bool isExcluded () const
 Boolean flag: is this peptide ratio excluded from protein ratio calculation?
bool isInfinite () const
 Boolean flag: is this ratio infinite?
bool isMissing () const
 Boolean flag: is this ratio undefined ("missing")?
ms_peptide_quant_ratiooperator= (const ms_peptide_quant_ratio &right)
 C++ assignment operator.

Detailed Description

Peptide abundance in one component relative to another in a quantitation experiment.

Peptide ratios can be calculated in many different ways depending on quantitation protocol. This class is merely a container of numerical values. It does not contain information about the quantitation method, protocol or parameters used in deriving the component intensities or the calculating ratio.

Each peptide ratio must be associated with a particular peptide quant key. For Reporter, this is the query number; for Multiplex, the query and rank of the identified peptide; and for other protocols, the peptide quant key can be a combination of peptide features. Query and rank refer to the standard Mascot convention, where query is the index of an input spectrum and rank is the index of an identified peptide matching the input spectrum.

Each peptide ratio object is associated with a ratio name. The ratio name is the name of a report ratio in a particular quantitation experiment. This can be any free form text, for example "115/114" or "control/diseased".

A peptide ratio may have an optional weighting factor, which by default is 1.0. Weighting factors are used in protein ratio calculation by ms_customquantitation.


Constructor & Destructor Documentation

ms_peptide_quant_ratio ( const ms_peptide_quant_key key,
const std::string &  ratioName,
bool  isInfinite = false 
)

Default constructor: create an infinite or undefined ("missing") peptide ratio associated with a particular peptide quant key and a ratio name.

An infinite or undefined ("missing") ratio is always excluded from protein ratio calculations. The return value of getValue() is undefined.

Parameters:
keyThe peptide quant key of the peptide ratio.
ratioNameThe name of the ratio, e.g. "115/114".
isInfiniteIf false (default), this peptide ratio is undefined ("missing"); if true, it is infinite. Use ms_peptide_quant_ratio(const ms_peptide_quant_key&, std::string, double, bool) to construct a finite peptide ratio.
ms_peptide_quant_ratio ( const ms_peptide_quant_key key,
const std::string &  ratioName,
double  value,
bool  isExcluded = false,
double  weight = 1.0 
)

Create a peptide ratio associated with a particular peptide quant key and ratio name.

If value is negative or 0, isExcluded will always be set to true, regardless of the argument value.

Parameters:
keyThe peptide quant key of the peptide ratio.
ratioNameThe name of the ratio, e.g. "115/114".
valueThe numerical value of this ratio. Usually ratios should be positive, but it is possible to give 0 or a negative value. Interpretation of such values is the caller's responsibility.
isExcluded(optional) If false (default for positive ratios), the peptide ratio can be included in protein ratio calculation; otherwise it should be excluded.
weight(optional) Weighting factor to use in weighted protein ratio calculation.

Member Function Documentation

bool isExcluded (  ) const

Boolean flag: is this peptide ratio excluded from protein ratio calculation?

If isInfinite() or isMissing() is true, so is the return value of this function. Otherwise, for a finite ratio, exclusion can depend on e.g. if the ratio is an outlier.

Returns:
True if this peptide ratio should be excluded from protein ratio calculations.
bool isInfinite (  ) const

Boolean flag: is this ratio infinite?

Infinite ratios can arise if the denominator is zero. Note that an infinite ratio is considered defined (not "missing"); that is, isMissing() will return false, even if the value is infinite.

If this method returns true, the return value of getValue() is undefined.

Returns:
True if the ratio is infinite; false otherwise.
bool isMissing (  ) const

Boolean flag: is this ratio undefined ("missing")?

The ratio can be undefined ("missing") if there is not enough data to calculate it. If this method returns true, the values of isInfinite() and getValue() are undefined.

Returns:
True if the ratio is missing; false otherwise.

The documentation for this class was generated from the following files:

Copyright © 2022 Matrix Science Ltd.  All Rights Reserved. Generated on Thu Mar 31 2022 01:12:35