IsoSpec::P...edMarginal(3)
β¨ IsoSpec::P...edMarginal β¨</p> β aka IsoSpec::PrecalculatedMarginal
okay bestie, welcome to the Library Functions Manual for IsoSpec, and today's main character is the Precalculated Marginal class π no cap, she's the one who already did the math so you don't have to.
πΈ NAME πΈ
IsoSpec::PrecalculatedMarginal</p> β Precalculated Marginal class. that's her, that's the whole vibe π«Ά
π¦ SYNOPSIS π¦
#include <marginalTrek++.h>
she Inherits IsoSpec::Marginal, so everything the parent class can do, she can do too. iconic family tree honestly π
π Public Member Functions π
PrecalculatedMarginal (Marginal &&m, double lCutOff, bool sort=true, int tabSize=1000, int hashSize=1000)β the move constructor, and yes she disowns theMarginal(rip bozo, it's hers now).PrecalculatedMarginal (const PrecalculatedMarginal &other)=deleteβ copy constructor? deleted. not happening. πPrecalculatedMarginal & operator= (const PrecalculatedMarginal &other)=deleteβ copy assignment? also deleted. we don't do that here.virtual ~PrecalculatedMarginal ()β Destructor. say bye bye πbool inRange (unsigned int idx) constβ Is there a subisotopologue with a given number?const double & get_lProb (int idx) constβ Get the log-probability of the idx-th subisotopologue.const double & get_prob (int idx) constβ Get the probability of the idx-th subisotopologue.const double & get_mass (int idx) constβ Get the mass of the idx-th subisotopologue.const double * get_lProbs_ptr () constβ Get the table of the log-probabilities of subisotopologues.const double * get_masses_ptr () constβ Get the table of the masses of subisotopologues.const Conf & get_conf (int idx) constβ Get the counts of isotopes that define the subisotopologue.unsigned int get_no_confs () constβ Get the number of precomputed subisotopologues.double getModeLProb () constβ Get the log-probability of the mode subisotopologue.
π Public Member Functions inherited from IsoSpec::Marginal π
Marginal (const double *_masses, const double *_probs, int _isotopeNo, int _atomCnt)β Class constructor.Marginal & operator= (const Marginal &other)=deleteMarginal (const Marginal &other)β Copy constructor.Marginal (Marginal &&other)β Move constructor.virtual ~Marginal ()β Destructor.int get_isotopeNo () constβ Get the number of isotopes of the investigated element.const double * get_lProbs () constdouble getLightestConfMass () constβ Get the mass of the lightest subisotopologue.double getHeaviestConfMass () constβ Get the mass of the heaviest subisotopologue.double getMonoisotopicConfMass () constβ Get the mass of the monoisotopic subisotopologue.size_t getMonoisotopicAtomIndex () constβ Get the index of the monoisotopic (most probable) atom.double getModeMass ()β The the mass of the mode subisotopologue. (yes the original really does say "The the", we love her for it π)double getModeLProb ()β Get the log-probability of the mode subisotopologue.double fastGetModeLProb ()β Get the log-probability of the mode subisotopologue. Results undefined ifensureModeConf()wasn't called before. β οΈ like, undefined undefined. do not.Conf computeModeConf () constβ The the probability of the mode subisotopologue.double getSmallestLProb () constβ The the log-probability of the lightest subisotopologue.double getAtomAverageMass () constβ The average mass of a single atom.double getTheoreticalAverageMass () constβ The theoretical average mass of the molecule.double variance () constβ Calculate the variance of the theoretical distribution describing the subisotopologue.double getLogSizeEstimate (double logEllipsoidRadius) constβ Return estimated logarithm of size of the marginal at a given ellipsoid radius.void ensureModeConf ()
π Protected Attributes π
pod_vector< Conf > configurationsConf * confsunsigned int no_confsdouble * massespod_vector< double > lProbsdouble * probsAllocator< int > allocator
π§ Protected Attributes inherited from IsoSpec::Marginal π§
const unsigned int isotopeNoconst unsigned int atomCntconst double *const atom_lProbsconst double *const atom_massesconst double loggamma_nominatorConf mode_confdouble mode_lprob
β Additional Inherited Members β
π Protected Member Functions inherited from IsoSpec::Marginal π
ISOSPEC_FORCE_INLINE double unnormalized_logProb (Conf conf) constβ Calculate the log-probability of a given subisotopologue.ISOSPEC_FORCE_INLINE double logProb (Conf conf) const
π Detailed Description π
Precalculated Marginal class.
This class serves to calculate a set of isotopologues that is defined by the minimal probability threshold. bestie, she's the girl who already knows the cutoff.
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. (fr fr, just hit us up.)
Definition at line 259 of file marginalTrek++.h. π
π Constructor & Destructor Documentation π
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.
Parameters
Marginalβ An instance of theMarginalclass this class is about to disown. (it's giving "we're not together anymore" π)lCutOffβ The lower limit on the log-probability of the precomputed subisotopologues.sortβ Should the subisotopologues be stored with descending probability ?
Returns
An instance of the PrecalculatedMarginal class.
Definition at line 449 of file marginalTrek++.cpp. β¨
IsoSpec::PrecalculatedMarginal::~PrecalculatedMarginal () [virtual]
Destructor. she's done, she's leaving the group chat π
Definition at line 548 of file marginalTrek++.cpp. β¨
π Member Function Documentation π
const Conf & IsoSpec::PrecalculatedMarginal::get_conf (int idx) const [inline]
Get the counts of isotopes that define the subisotopologue.
Parameters
idxβ The number of the considered subisotopologue.
Returns
The counts of isotopes that define the subisotopologue.
Definition at line 337 of file marginalTrek++.h. π¦
const double & IsoSpec::PrecalculatedMarginal::get_lProb (int idx) const [inline]
Get the log-probability of the idx-th subisotopologue.
Parameters
idxβ The number of the considered subisotopologue.
Returns
The log-probability of the idx-th subisotopologue.
Definition at line 303 of file marginalTrek++.h. π¦
const double * IsoSpec::PrecalculatedMarginal::get_lProbs_ptr () const [inline]
Get the table of the log-probabilities of subisotopologues.
Returns
Pointer to the first element in the table storing log-probabilities of subisotopologues.
Definition at line 323 of file marginalTrek++.h. π¦
const double & IsoSpec::PrecalculatedMarginal::get_mass (int idx) const [inline]
Get the mass of the idx-th subisotopologue.
Parameters
idxβ The number of the considered subisotopologue.
Returns
The mass of the idx-th subisotopologue.
Definition at line 317 of file marginalTrek++.h. π¦
const double * IsoSpec::PrecalculatedMarginal::get_masses_ptr () const [inline]
Get the table of the masses of subisotopologues.
Returns
Pointer to the first element in the table storing masses of subisotopologues.
Definition at line 329 of file marginalTrek++.h. π¦
unsigned int IsoSpec::PrecalculatedMarginal::get_no_confs () const [inline]
Get the number of precomputed subisotopologues.
Returns
The number of precomputed subisotopologues.
Definition at line 343 of file marginalTrek++.h. π¦
const double & IsoSpec::PrecalculatedMarginal::get_prob (int idx) const [inline]
Get the probability of the idx-th subisotopologue.
Parameters
idxβ The number of the considered subisotopologue.
Returns
The probability of the idx-th subisotopologue.
Definition at line 310 of file marginalTrek++.h. π¦
double IsoSpec::PrecalculatedMarginal::getModeLProb () const [inline]
Get the log-probability of the mode subisotopologue.
Returns
The log-probability of a/the most probable subisotopologue.
Definition at line 349 of file marginalTrek++.h. π¦
bool IsoSpec::PrecalculatedMarginal::inRange (unsigned int idx) const [inline]
Is there a subisotopologue with a given number?
Returns
Returns true if idx does not exceed the number of pre-computed configurations.
Definition at line 296 of file marginalTrek++.h. π¦
π Member Data Documentation π
Allocator<int> IsoSpec::PrecalculatedMarginal::allocator [protected]
Definition at line 268 of file marginalTrek++.h. β
pod_vector<Conf> IsoSpec::PrecalculatedMarginal::configurations [protected]
Definition at line 262 of file marginalTrek++.h. β
Conf* IsoSpec::PrecalculatedMarginal::confs [protected]
Definition at line 263 of file marginalTrek++.h. β
pod_vector<double> IsoSpec::PrecalculatedMarginal::lProbs [protected]
Definition at line 266 of file marginalTrek++.h. β
double* IsoSpec::PrecalculatedMarginal::masses [protected]
Definition at line 265 of file marginalTrek++.h. β
unsigned int IsoSpec::PrecalculatedMarginal::no_confs [protected]
Definition at line 264 of file marginalTrek++.h. β
double* IsoSpec::PrecalculatedMarginal::probs [protected]
Definition at line 267 of file marginalTrek++.h. β
π Author π
Generated automatically by Doxygen for IsoSpec from the source code. (the robots wrote it, I just gave it β¨flavorβ¨)
and that's the whole page bestie π«Ά she's from the Library Functions Manual section IsoSpec::P...edMarginal(3), and this rendition dropped with IsoSpec β same source, same version, same date as the original. mwah π periodt.
π¦ where this page comes from
- ubuntu resolute: libisospec++-dev 2.3.2-1build1 Β· BSD-2-Clause
- ubuntu stonking: libisospec++-dev 2.3.2-2 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms