![]() |
IsoSpec
1.95
|
Precalculated Marginal class. More...
#include <marginalTrek++.h>
Public Member Functions | |
PrecalculatedMarginal (Marginal &&m, double lCutOff, bool sort=true, int tabSize=1000, int hashSize=1000) | |
The move constructor (disowns the Marginal). More... | |
virtual | ~PrecalculatedMarginal () |
Destructor. | |
bool | inRange (unsigned int idx) const |
Is there a subisotopologue with a given number? More... | |
const double & | get_lProb (int idx) const |
Get the log-probability of the idx-th subisotopologue. More... | |
const double & | get_prob (int idx) const |
Get the probability of the idx-th subisotopologue. More... | |
const double & | get_mass (int idx) const |
Get the mass of the idx-th subisotopologue. More... | |
const double * | get_lProbs_ptr () const |
Get the table of the log-probabilities of subisotopologues. More... | |
const double * | get_masses_ptr () const |
Get the table of the masses of subisotopologues. More... | |
const Conf & | get_conf (int idx) const |
Get the counts of isotopes that define the subisotopologue. More... | |
unsigned int | get_no_confs () const |
Get the number of precomputed subisotopologues. More... | |
![]() | |
Marginal (const double *_masses, const double *_probs, int _isotopeNo, int _atomCnt) | |
Class constructor. More... | |
Marginal (Marginal &other)=delete | |
Marginal & | operator= (const Marginal &other)=delete |
Marginal (Marginal &&other) | |
Move constructor. | |
virtual | ~Marginal () |
Destructor. | |
int | get_isotopeNo () const |
Get the number of isotopes of the investigated element. More... | |
const double * | get_lProbs () const |
double | getLightestConfMass () const |
Get the mass of the lightest subisotopologue. More... | |
double | getHeaviestConfMass () const |
Get the mass of the heaviest subisotopologue. More... | |
double | getMonoisotopicConfMass () const |
Get the mass of the monoisotopic subisotopologue. More... | |
double | getModeLProb () const |
Get the log-probability of the mode subisotopologue. More... | |
double | getModeMass () const |
The the mass of the mode subisotopologue. More... | |
double | getModeProb () const |
The the probability of the mode subisotopologue. More... | |
double | getSmallestLProb () const |
The the log-probability of the lightest subisotopologue. More... | |
double | getTheoreticalAverageMass () const |
The theoretical average mass of the molecule. More... | |
double | logProb (Conf conf) const |
Calculate the log-probability of a given subisotopologue. More... | |
Protected Attributes | |
std::vector< Conf > | configurations |
Conf * | confs |
unsigned int | no_confs |
double * | masses |
double * | lProbs |
double * | probs |
Allocator< int > | allocator |
![]() | |
const unsigned int | isotopeNo |
const unsigned int | atomCnt |
const double *const | atom_lProbs |
const double *const | atom_masses |
const double | loggamma_nominator |
const Conf | mode_conf |
const double | mode_lprob |
const double | mode_mass |
const double | mode_prob |
const double | smallest_lprob |
Precalculated Marginal class.
This class serves to calculate a set of isotopologues that is defined by the minimal probability threshold.
This works faster than if you did not know the threshold. If you have no idea about the threshold, you would need to call us, to change encode the layered version of the marginal.
Definition at line 226 of file marginalTrek++.h.
IsoSpec::PrecalculatedMarginal::PrecalculatedMarginal | ( | Marginal && | m, |
double | lCutOff, | ||
bool | sort = true , |
||
int | tabSize = 1000 , |
||
int | hashSize = 1000 |
||
) |
The move constructor (disowns the Marginal).
This constructor memoizes all subisotopologues with log-probability above the provided threshold lCutOff
Marginal | An instance of the Marginal class this class is about to disown. |
lCutOff | The lower limit on the log-probability of the precomputed subisotopologues. |
sort | Should the subisotopologues be stored with descending probability ? |
Definition at line 390 of file marginalTrek++.cpp.
|
inline |
Get the counts of isotopes that define the subisotopologue.
idx | The number of the considered subisotopologue. |
Definition at line 301 of file marginalTrek++.h.
|
inline |
Get the log-probability of the idx-th subisotopologue.
idx | The number of the considered subisotopologue. |
Definition at line 267 of file marginalTrek++.h.
|
inline |
Get the table of the log-probabilities of subisotopologues.
Definition at line 287 of file marginalTrek++.h.
|
inline |
Get the mass of the idx-th subisotopologue.
idx | The number of the considered subisotopologue. |
Definition at line 281 of file marginalTrek++.h.
|
inline |
Get the table of the masses of subisotopologues.
Definition at line 293 of file marginalTrek++.h.
|
inline |
Get the number of precomputed subisotopologues.
Definition at line 307 of file marginalTrek++.h.
|
inline |
Get the probability of the idx-th subisotopologue.
idx | The number of the considered subisotopologue. |
Definition at line 274 of file marginalTrek++.h.
|
inline |
Is there a subisotopologue with a given number?
Definition at line 260 of file marginalTrek++.h.