Chemical Data Processing Library C++ API - Version 1.2.0
Public Member Functions | Static Public Attributes | List of all members
CDPL::MolProp::XLogPCalculator Class Reference

XLogPCalculator. More...

#include <XLogPCalculator.hpp>

Public Member Functions

 XLogPCalculator ()
 Constructs the XLogPCalculator instance. More...
 
 XLogPCalculator (const Chem::MolecularGraph &molgraph)
 Constructs the LogSCalculator instance and calculates the \( \log P \) of the molecular graph molgraph. More...
 
double calculate (const Chem::MolecularGraph &molgraph)
 Calculates the \( \log P \) of the molecular graph molgraph. More...
 
double getResult () const
 Returns the result of the last \( \log P \) calculation. More...
 
const Math::DVectorgetFeatureVector () const
 Returns the feature count vector of the last \( \log P \) calculation. More...
 
const Math::DVectorgetAtomContributions () const
 Returns the contribution of each atom the total obtained by the last \( \log P \) calculation. More...
 

Static Public Attributes

static constexpr std::size_t FEATURE_VECTOR_SIZE = 101
 Specifies the number of different structural features used by the \( \log P \) model. More...
 

Detailed Description

XLogPCalculator.

See also
[XLOGP]

Constructor & Destructor Documentation

◆ XLogPCalculator() [1/2]

CDPL::MolProp::XLogPCalculator::XLogPCalculator ( )

Constructs the XLogPCalculator instance.

◆ XLogPCalculator() [2/2]

CDPL::MolProp::XLogPCalculator::XLogPCalculator ( const Chem::MolecularGraph molgraph)

Constructs the LogSCalculator instance and calculates the \( \log P \) of the molecular graph molgraph.

The calculated \( \log P \) can be retrieved by a call to getResult().

Parameters
molgraphThe molecular graph for which to calculate the \( \log P \).

Member Function Documentation

◆ calculate()

double CDPL::MolProp::XLogPCalculator::calculate ( const Chem::MolecularGraph molgraph)

Calculates the \( \log P \) of the molecular graph molgraph.

Parameters
molgraphThe molecular graph for which to calculate the \( \log P \).
Returns
The calculated \( \log P \) of the molecular graph molgraph.

◆ getResult()

double CDPL::MolProp::XLogPCalculator::getResult ( ) const

Returns the result of the last \( \log P \) calculation.

Returns
The result of the last \( \log P \) calculation, or zero if a calculation has not yet been performed.

◆ getFeatureVector()

const Math::DVector& CDPL::MolProp::XLogPCalculator::getFeatureVector ( ) const

Returns the feature count vector of the last \( \log P \) calculation.

The occurrence count of a particular structural feature (atom type or correction factor feature) can be retrieved from the returned vector via its feature index. For atom type related features, the feature index correspond to the numerical identifier of the atom type in the original publication [XLOGP] minus 1. The feature indices of the various correction factors start at index 90 and are ordered according to their definition in the paper.

Returns
The feature count vector of the last \( \log P \) calculation.
Note
The returned feature vector is of size XLogPCalculator::FEATURE_VECTOR_SIZE.

◆ getAtomContributions()

const Math::DVector& CDPL::MolProp::XLogPCalculator::getAtomContributions ( ) const

Returns the contribution of each atom the total obtained by the last \( \log P \) calculation.

Returns
The contribution of each atom the total \( \log P \).
Note
The sum of the atom contributions does not necessarily equal the calculated molecule \( \log P \) and might be lower!
See also
XLogPCalculator::calculate()

Member Data Documentation

◆ FEATURE_VECTOR_SIZE

constexpr std::size_t CDPL::MolProp::XLogPCalculator::FEATURE_VECTOR_SIZE = 101
staticconstexpr

Specifies the number of different structural features used by the \( \log P \) model.


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