11 #include <OpenMS/OpenMSConfig.h>
31 Adduct(
Int charge,
Int amount,
double singleMass,
const String& formula,
double log_prob,
double rt_shift,
const String& label =
"");
void setLogProb(const double &log_prob)
String checkFormula_(const String &formula)
Adduct operator+(const Adduct &rhs)
Add two adducts amount if they are equal (defined by equal formula)
double log_prob_
log probability of observing a single entity of this adduct
Definition: Adduct.h:75
void setCharge(const Int &charge)
Adduct operator*(const Int m) const
Increase amount of this adduct by factor.
friend bool operator==(const Adduct &a, const Adduct &b)
Comparator.
String formula_
chemical formula (parsable by EmpiricalFormula)
Definition: Adduct.h:76
void setAmount(const Int &amount)
String toAdductString(const String &ion_string, const Int &charge)
void operator+=(const Adduct &rhs)
Add other adducts amount to *this (equal formula required!)
const double & getLogProb() const
Adduct(Int charge)
C'tor with initial charge.
String label_
Label for this adduct (can be used to indicate heavy labels)
Definition: Adduct.h:78
double rt_shift_
RT shift induced by a single entity of this adduct (this is for adducts attached prior to ESI,...
Definition: Adduct.h:77
const String & getLabel() const
std::vector< Adduct > AdductsType
Definition: Adduct.h:22
void setSingleMass(const double &singleMass)
const String & getFormula() const
Adduct(Int charge, Int amount, double singleMass, const String &formula, double log_prob, double rt_shift, const String &label="")
C'tor for all members.
void setFormula(const String &formula)
const double & getSingleMass() const
double singleMass_
mass of a single entity
Definition: Adduct.h:74
const Int & getAmount() const
const Int & getCharge() const
Int amount_
number of entities
Definition: Adduct.h:73
const double & getRTShift() const
Int charge_
usually +1
Definition: Adduct.h:72
friend std::ostream & operator<<(std::ostream &os, const Adduct &a)
Print the contents of an Adduct to a stream.
A more convenient string class.
Definition: String.h:34
int Int
Signed integer type.
Definition: Types.h:76
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:22