bpp-core3  3.0.0
bpp::HmmLikelihood Class Referenceabstract

Basal interface for Hidden Markov Models likelihood computation. More...

#include <Bpp/Numeric/Hmm/HmmLikelihood.h>

+ Inheritance diagram for bpp::HmmLikelihood:
+ Collaboration diagram for bpp::HmmLikelihood:

Public Member Functions

virtual HmmLikelihoodclone () const =0
 Create a copy of this object and send a pointer to it. More...
 
virtual const HmmStateAlphabethmmStateAlphabet () const =0
 
virtual HmmStateAlphabethmmStateAlphabet ()=0
 
virtual std::shared_ptr< const HmmStateAlphabetgetHmmStateAlphabet () const =0
 
virtual std::shared_ptr< HmmStateAlphabetgetHmmStateAlphabet ()=0
 
virtual const HmmTransitionMatrixhmmTransitionMatrix () const =0
 
virtual HmmTransitionMatrixhmmTransitionMatrix ()=0
 
virtual std::shared_ptr< const HmmTransitionMatrixgetHmmTransitionMatrix () const =0
 
virtual std::shared_ptr< HmmTransitionMatrixgetHmmTransitionMatrix ()=0
 
virtual const HmmEmissionProbabilitieshmmEmissionProbabilities () const =0
 
virtual HmmEmissionProbabilitieshmmEmissionProbabilities ()=0
 
virtual std::shared_ptr< const HmmEmissionProbabilitiesgetHmmEmissionProbabilities () const =0
 
virtual std::shared_ptr< HmmEmissionProbabilitiesgetHmmEmissionProbabilities ()=0
 
virtual void getHiddenStatesPosteriorProbabilities (std::vector< std::vector< double >> &probs, bool append) const =0
 
virtual Vdouble getHiddenStatesPosteriorProbabilitiesForASite (size_t site) const =0
 
virtual double getLogLikelihood () const =0
 
virtual double getDLogLikelihood () const =0
 
virtual double getD2LogLikelihood () const =0
 
virtual double getLikelihoodForASite (size_t site) const =0
 Get the likelihood for a site, and its derivatives. More...
 
virtual double getDLogLikelihoodForASite (size_t site) const =0
 
virtual double getD2LogLikelihoodForASite (size_t site) const =0
 
virtual Vdouble getLikelihoodForEachSite () const =0
 Get the likelihood for each site. More...
 
virtual const std::vector< size_t > & getBreakPoints () const =0
 
virtual void setBreakPoints (const std::vector< size_t > &breakPoints)=0
 
virtual void enableSecondOrderDerivatives (bool yn)=0
 Tell if derivatives must be computed. More...
 
virtual bool enableSecondOrderDerivatives () const =0
 Tell if derivatives must be computed. More...
 
virtual double getSecondOrderDerivative (const std::string &variable) const =0
 Get the second order derivative of the function at the current point. More...
 
virtual double getSecondOrderDerivative (const std::string &variable1, const std::string &variable2) const =0
 Get the value of the cross derivative of the function according to a given set of parameters. More...
 
virtual double d2f (const std::string &variable, const ParameterList &parameters)
 Get the value of the second order derivative of the function according to a given set of parameters. More...
 
virtual double d2f (const std::string &variable1, const std::string &variable2, const ParameterList &parameters)
 Get the value of the cross derivative of the function according to a given set of parameters. More...
 
virtual void enableFirstOrderDerivatives (bool yn)=0
 Tell if derivatives must be computed. More...
 
virtual bool enableFirstOrderDerivatives () const =0
 Tell if derivatives must be computed. More...
 
virtual double getFirstOrderDerivative (const std::string &variable) const =0
 Get the derivative of the function at the current point. More...
 
virtual double df (const std::string &variable, const ParameterList &parameters)
 Get the value of the first derivative of the function according to a given set of parameters. More...
 
virtual void setParameters (const ParameterList &parameters)=0
 Set the point where the function must be computed. More...
 
virtual double getValue () const =0
 Get the value of the function at the current point. More...
 
virtual double f (const ParameterList &parameters)
 Get the value of the function according to a given set of parameters. More...
 
virtual bool hasParameter (const std::string &name) const =0
 Tell if there is a parameter with specified name. More...
 
virtual const ParameterListgetParameters () const =0
 Get all parameters available. More...
 
virtual const Parameterparameter (const std::string &name) const =0
 Get the parameter with specified name. More...
 
virtual double getParameterValue (const std::string &name) const =0
 Get the value for parameter of name 'name'. More...
 
virtual void setAllParametersValues (const ParameterList &parameters)=0
 Set the parameters values to be equals to those of parameters. More...
 
virtual void setParameterValue (const std::string &name, double value)=0
 Set the value of parameter with name name to be equal to value. More...
 
virtual void setParametersValues (const ParameterList &parameters)=0
 Update the parameters from parameters. More...
 
virtual bool matchParametersValues (const ParameterList &parameters)=0
 Update the parameters from parameters. More...
 
virtual void removeConstraint (const std::string &name)=0
 Remove the constraint associated with one parameter, if any. More...
 
virtual void setConstraint (const std::string &name, std::shared_ptr< ConstraintInterface > constraint)=0
 Set/Change the constraint associated with one parameter. More...
 
virtual size_t getNumberOfParameters () const =0
 Get the number of parameters. More...
 
virtual void setNamespace (const std::string &prefix)=0
 Set the namespace for the parameter names. More...
 
virtual std::string getNamespace () const =0
 
virtual std::string getParameterNameWithoutNamespace (const std::string &name) const =0
 Resolves a parameter name according to the current namespace. More...
 

Protected Member Functions

virtual void computeDLikelihood_ () const =0
 
virtual void computeD2Likelihood_ () const =0
 
virtual ParameterListgetParameters_ ()=0
 Get all parameters available. More...
 

Detailed Description

Basal interface for Hidden Markov Models likelihood computation.

HmmLikelihood classes compute the probability of data according to parameters (likelihood), using the so-called forward recursion:

  • Initialisation:

    \[ f_0({\cal A}_0), \ldots, f_0({\cal A}_n) \]

    The initial frequencies, set to the equilibrium frequencies of the chain.
  • Recursion (for i=1 to l, the length of the sequence data):

    \[ f_i({\cal A}_y) = e_y(D_i) \sum_{x=1}^n f_{i-1}({\cal A}_x) \cdot p_{x,y} \]

  • Termination:

    \[ \Pr(D) = \sum_{x=1}^n f_l({\cal A}_x) \]

    where $ {\cal A}_{1..n} $ denotes the hidden states of the alphabet, $ e_y(D_i) $ the probability of the data at position i conditioned on hidden state y (emission probabilities) and $ p_{x,y} $ is the probability of havving hidden state y at state i+1 knowing there is hidden state x at position i (transition probabilities). These essential elements are given respectively by the HmmEmissionProbabilities and HmmTransitionMatrix object associated to this class. Both objects have to share the same HmmStateAlphabet instance, which describes all allowed hidden states.

The HmmLikelihood interface provides essentially two major methods:

  • A method to retrieve the likelihood value (parameter estimation)
  • Two methods to retrieve the posterio probabilities of each state using the forward and backward conditionnal likelihoods (posterior decoding).

Definition at line 41 of file HmmLikelihood.h.

Member Function Documentation

◆ clone()

virtual HmmLikelihood* bpp::HmmLikelihood::clone ( ) const
pure virtual

Create a copy of this object and send a pointer to it.

Returns
A pointer toward the copy object.

Implements bpp::SecondOrderDerivable.

Implemented in bpp::LogsumHmmLikelihood, bpp::RescaledHmmLikelihood, and bpp::LowMemoryRescaledHmmLikelihood.

◆ computeD2Likelihood_()

virtual void bpp::HmmLikelihood::computeD2Likelihood_ ( ) const
protectedpure virtual

◆ computeDLikelihood_()

virtual void bpp::HmmLikelihood::computeDLikelihood_ ( ) const
protectedpure virtual

◆ d2f() [1/2]

virtual double bpp::SecondOrderDerivable::d2f ( const std::string &  variable,
const ParameterList parameters 
)
inlinevirtualinherited

Get the value of the second order derivative of the function according to a given set of parameters.

Parameters
variableThe name of the $ x $ variable in $ \frac{\partial^2 f}{\partial x^2} $.
parametersThe parameter set to pass to the function.
Returns
The value of the function with the given parameter set.
Exceptions
ExceptionIf an error occured.

Definition at line 193 of file Functions.h.

References bpp::FunctionInterface::setParameters().

◆ d2f() [2/2]

virtual double bpp::SecondOrderDerivable::d2f ( const std::string &  variable1,
const std::string &  variable2,
const ParameterList parameters 
)
inlinevirtualinherited

Get the value of the cross derivative of the function according to a given set of parameters.

Parameters
variable1The name of the $ x $ variable in $ \frac{\partial^2 f}{\partial x \partial y} $.
variable2The name of the $ y $ variable in $ \frac{\partial^2 f}{\partial x \partial y} $.
parametersThe parameter set to pass to the function.
Returns
The value of the function with the given parameter set.
Exceptions
ExceptionIf an error occured.

Definition at line 220 of file Functions.h.

References bpp::FunctionInterface::setParameters().

◆ df()

virtual double bpp::FirstOrderDerivable::df ( const std::string &  variable,
const ParameterList parameters 
)
inlinevirtualinherited

Get the value of the first derivative of the function according to a given set of parameters.

Parameters
variableThe name of the $ x $ variable in $ \frac{df}{dx} $.
parametersThe parameter set to pass to the function.
Returns
The value of the function with the given parameter set.
Exceptions
ExceptionIf an error occured.

Definition at line 138 of file Functions.h.

References bpp::FunctionInterface::setParameters().

◆ enableFirstOrderDerivatives() [1/2]

virtual void bpp::FirstOrderDerivable::enableFirstOrderDerivatives ( bool  yn)
pure virtualinherited

◆ enableFirstOrderDerivatives() [2/2]

virtual bool bpp::FirstOrderDerivable::enableFirstOrderDerivatives ( ) const
pure virtualinherited

◆ enableSecondOrderDerivatives() [1/2]

virtual void bpp::SecondOrderDerivable::enableSecondOrderDerivatives ( bool  yn)
pure virtualinherited

◆ enableSecondOrderDerivatives() [2/2]

virtual bool bpp::SecondOrderDerivable::enableSecondOrderDerivatives ( ) const
pure virtualinherited

◆ f()

virtual double bpp::FunctionInterface::f ( const ParameterList parameters)
inlinevirtualinherited

Get the value of the function according to a given set of parameters.

Parameters
parametersThe parameter set to pass to the function.
Returns
The value of the function with the given parameter set.
Exceptions
ExceptionIf an error occured.

Reimplemented in bpp::InfinityFunctionWrapper, bpp::FunctionWrapper, and bpp::AbstractNumericalDerivative.

Definition at line 82 of file Functions.h.

References bpp::FunctionInterface::getValue(), and bpp::FunctionInterface::setParameters().

Referenced by bpp::NumTools::uniRoot().

◆ getBreakPoints()

virtual const std::vector<size_t>& bpp::HmmLikelihood::getBreakPoints ( ) const
pure virtual

◆ getD2LogLikelihood()

virtual double bpp::HmmLikelihood::getD2LogLikelihood ( ) const
pure virtual

Implemented in bpp::AbstractHmmLikelihood.

◆ getD2LogLikelihoodForASite()

virtual double bpp::HmmLikelihood::getD2LogLikelihoodForASite ( size_t  site) const
pure virtual

◆ getDLogLikelihood()

virtual double bpp::HmmLikelihood::getDLogLikelihood ( ) const
pure virtual

Implemented in bpp::AbstractHmmLikelihood.

◆ getDLogLikelihoodForASite()

virtual double bpp::HmmLikelihood::getDLogLikelihoodForASite ( size_t  site) const
pure virtual

◆ getFirstOrderDerivative()

virtual double bpp::FirstOrderDerivable::getFirstOrderDerivative ( const std::string &  variable) const
pure virtualinherited

Get the derivative of the function at the current point.

Parameters
variableThe name of the $ x $ variable in $ \frac{df}{dx} $.
Returns
The value of the function.
Exceptions
ExceptionIf no point is specified or if an error occured.

Implemented in bpp::FirstOrderDerivableWrapper, bpp::ReparametrizationDerivableFirstOrderWrapper, bpp::AbstractNumericalDerivative, and bpp::AbstractHmmLikelihood.

Referenced by bpp::NewtonOneDimension::doStep(), bpp::AbstractHmmLikelihood::enableFirstOrderDerivatives(), bpp::ConjugateGradientMultiDimensions::getGradient(), and bpp::BfgsMultiDimensions::getGradient().

◆ getHiddenStatesPosteriorProbabilities()

virtual void bpp::HmmLikelihood::getHiddenStatesPosteriorProbabilities ( std::vector< std::vector< double >> &  probs,
bool  append 
) const
pure virtual

◆ getHiddenStatesPosteriorProbabilitiesForASite()

virtual Vdouble bpp::HmmLikelihood::getHiddenStatesPosteriorProbabilitiesForASite ( size_t  site) const
pure virtual

◆ getHmmEmissionProbabilities() [1/2]

virtual std::shared_ptr<const HmmEmissionProbabilities> bpp::HmmLikelihood::getHmmEmissionProbabilities ( ) const
pure virtual

◆ getHmmEmissionProbabilities() [2/2]

virtual std::shared_ptr<HmmEmissionProbabilities> bpp::HmmLikelihood::getHmmEmissionProbabilities ( )
pure virtual

◆ getHmmStateAlphabet() [1/2]

virtual std::shared_ptr<const HmmStateAlphabet> bpp::HmmLikelihood::getHmmStateAlphabet ( ) const
pure virtual

◆ getHmmStateAlphabet() [2/2]

virtual std::shared_ptr<HmmStateAlphabet> bpp::HmmLikelihood::getHmmStateAlphabet ( )
pure virtual

◆ getHmmTransitionMatrix() [1/2]

virtual std::shared_ptr<const HmmTransitionMatrix> bpp::HmmLikelihood::getHmmTransitionMatrix ( ) const
pure virtual

◆ getHmmTransitionMatrix() [2/2]

virtual std::shared_ptr<HmmTransitionMatrix> bpp::HmmLikelihood::getHmmTransitionMatrix ( )
pure virtual

◆ getLikelihoodForASite()

virtual double bpp::HmmLikelihood::getLikelihoodForASite ( size_t  site) const
pure virtual

Get the likelihood for a site, and its derivatives.

Parameters
siteThe site index to analyse.
Returns
The likelihood for site site.

Implemented in bpp::LogsumHmmLikelihood, bpp::RescaledHmmLikelihood, and bpp::LowMemoryRescaledHmmLikelihood.

◆ getLikelihoodForEachSite()

virtual Vdouble bpp::HmmLikelihood::getLikelihoodForEachSite ( ) const
pure virtual

Get the likelihood for each site.

Returns
A vector with all likelihoods for each site.

Implemented in bpp::LogsumHmmLikelihood, bpp::RescaledHmmLikelihood, and bpp::LowMemoryRescaledHmmLikelihood.

◆ getLogLikelihood()

virtual double bpp::HmmLikelihood::getLogLikelihood ( ) const
pure virtual

◆ getNamespace()

virtual std::string bpp::Parametrizable::getNamespace ( ) const
pure virtualinherited
Returns
The current namespace used. This is an empty string if no namespace is currently defined.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ getNumberOfParameters()

virtual size_t bpp::Parametrizable::getNumberOfParameters ( ) const
pure virtualinherited

Get the number of parameters.

See also
getNumberOfIndependentParameters If some parameters are aliased.
Returns
The number of parameters.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, bpp::AbstractParametrizable, and bpp::DirectionFunction.

Referenced by bpp::BppODiscreteDistributionFormat::writeDiscreteDistribution(), and bpp::Parametrizable::~Parametrizable().

◆ getParameterNameWithoutNamespace()

virtual std::string bpp::Parametrizable::getParameterNameWithoutNamespace ( const std::string &  name) const
pure virtualinherited

Resolves a parameter name according to the current namespace.

Returns
The parameter name without the namespace prefix, if any.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::BppODiscreteDistributionFormat::readDiscreteDistribution(), bpp::BppOParametrizableFormat::write(), and bpp::Parametrizable::~Parametrizable().

◆ getParameters()

virtual const ParameterList& bpp::Parametrizable::getParameters ( ) const
pure virtualinherited

◆ getParameters_()

virtual ParameterList& bpp::Parametrizable::getParameters_ ( )
protectedpure virtualinherited

Get all parameters available.

See also
getIndependentParameters if some parameters are aliased.
Returns
A list with all parameters available.

Implemented in bpp::FunctionWrapper, bpp::AbstractParametrizable, and bpp::DirectionFunction.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ getParameterValue()

virtual double bpp::Parametrizable::getParameterValue ( const std::string &  name) const
pure virtualinherited

Get the value for parameter of name 'name'.

Parameters
nameThe name of the parameter.
Returns
the value of parameter name.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::BppODiscreteDistributionFormat::readDiscreteDistribution(), and bpp::Parametrizable::~Parametrizable().

◆ getSecondOrderDerivative() [1/2]

virtual double bpp::SecondOrderDerivable::getSecondOrderDerivative ( const std::string &  variable) const
pure virtualinherited

Get the second order derivative of the function at the current point.

Parameters
variableThe name of the $ x $ variable in $ \frac{\partial^2 f}{\partial x^2} $.
Returns
The value of the function.
Exceptions
ExceptionIf no point is specified or if an error occured.

Implemented in bpp::SecondOrderDerivableWrapper, bpp::ReparametrizationDerivableSecondOrderWrapper, bpp::AbstractNumericalDerivative, bpp::AbstractHmmLikelihood, and bpp::TwoPointsNumericalDerivative.

Referenced by bpp::NewtonOneDimension::doStep(), and bpp::AbstractHmmLikelihood::enableSecondOrderDerivatives().

◆ getSecondOrderDerivative() [2/2]

virtual double bpp::SecondOrderDerivable::getSecondOrderDerivative ( const std::string &  variable1,
const std::string &  variable2 
) const
pure virtualinherited

Get the value of the cross derivative of the function according to a given set of parameters.

Parameters
variable1The name of the $ x $ variable in $ \frac{\partial^2 f}{\partial x \partial y} $.
variable2The name of the $ y $ variable in $ \frac{\partial^2 f}{\partial x \partial y} $.
Returns
The value of the function with the given parameter set.
Exceptions
ExceptionIf an error occured.

Implemented in bpp::SecondOrderDerivableWrapper, bpp::ReparametrizationDerivableSecondOrderWrapper, bpp::AbstractNumericalDerivative, bpp::AbstractHmmLikelihood, bpp::FivePointsNumericalDerivative, and bpp::TwoPointsNumericalDerivative.

◆ getValue()

◆ hasParameter()

virtual bool bpp::Parametrizable::hasParameter ( const std::string &  name) const
pure virtualinherited

Tell if there is a parameter with specified name.

Parameters
nameThe name of the parameter to look for.
Returns
y/n.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ hmmEmissionProbabilities() [1/2]

◆ hmmEmissionProbabilities() [2/2]

virtual HmmEmissionProbabilities& bpp::HmmLikelihood::hmmEmissionProbabilities ( )
pure virtual

◆ hmmStateAlphabet() [1/2]

virtual const HmmStateAlphabet& bpp::HmmLikelihood::hmmStateAlphabet ( ) const
pure virtual

◆ hmmStateAlphabet() [2/2]

virtual HmmStateAlphabet& bpp::HmmLikelihood::hmmStateAlphabet ( )
pure virtual

◆ hmmTransitionMatrix() [1/2]

virtual const HmmTransitionMatrix& bpp::HmmLikelihood::hmmTransitionMatrix ( ) const
pure virtual

◆ hmmTransitionMatrix() [2/2]

virtual HmmTransitionMatrix& bpp::HmmLikelihood::hmmTransitionMatrix ( )
pure virtual

◆ matchParametersValues()

virtual bool bpp::Parametrizable::matchParametersValues ( const ParameterList parameters)
pure virtualinherited

Update the parameters from parameters.

Only common parameters with parameters will be updated.

Parameters
parametersA list of parameters.
Returns
True if at least one parameter value has been changed.
Exceptions
ConstraintExceptionIf a value in parameters does not match the constraint in the corresponding parameter in the list.

Implemented in bpp::InfinityFunctionWrapper, bpp::FunctionWrapper, bpp::AbstractNumericalDerivative, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::BppODiscreteDistributionFormat::initialize_(), bpp::TestFunction::setParameters(), and bpp::Parametrizable::~Parametrizable().

◆ parameter()

virtual const Parameter& bpp::Parametrizable::parameter ( const std::string &  name) const
pure virtualinherited

Get the parameter with specified name.

Parameters
nameThe name of the parameter to look for.
Returns
The parameter with given name.
Exceptions
ParameterNotFoundExceptionif no parameter with this name is found.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::TestFunction::getValue(), and bpp::Parametrizable::~Parametrizable().

◆ removeConstraint()

virtual void bpp::Parametrizable::removeConstraint ( const std::string &  name)
pure virtualinherited

Remove the constraint associated with one parameter, if any.

Parameters
nameThe name of the parameter to look for.
Exceptions
ParameterNotFoundExceptionif no parameter with this name is found.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ setAllParametersValues()

virtual void bpp::Parametrizable::setAllParametersValues ( const ParameterList parameters)
pure virtualinherited

Set the parameters values to be equals to those of parameters.

The list must contain exactly the same parameters (ie same names) than the parameters available.

Parameters
parametersA list with all parameters.
Exceptions
ParameterNotFoundExceptionIf a some parameter in the list is not in params.
ConstraintExceptionIf a value in parameters does not match the constraint in the corresponding parameter in the list.

Implemented in bpp::InfinityFunctionWrapper, bpp::FunctionWrapper, bpp::AbstractNumericalDerivative, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ setBreakPoints()

virtual void bpp::HmmLikelihood::setBreakPoints ( const std::vector< size_t > &  breakPoints)
pure virtual

◆ setConstraint()

virtual void bpp::Parametrizable::setConstraint ( const std::string &  name,
std::shared_ptr< ConstraintInterface constraint 
)
pure virtualinherited

Set/Change the constraint associated with one parameter.

Parameters
nameThe name of the parameter to look for.
constraintA pointer to the constraint (may be null)
Exceptions
ParameterNotFoundExceptionif no parameter with this name is found.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ setNamespace()

virtual void bpp::Parametrizable::setNamespace ( const std::string &  prefix)
pure virtualinherited

Set the namespace for the parameter names.

Parameters
prefixThe 'namespace', that is a prefix to add to all parameter names. If parameter names are already prefixed, the new prefix will be used instead.

Implemented in bpp::FunctionWrapper, bpp::ParametrizableAdapter, bpp::LogsumHmmLikelihood, bpp::RescaledHmmLikelihood, bpp::LowMemoryRescaledHmmLikelihood, bpp::AbstractParameterAliasable, bpp::MixtureOfDiscreteDistributions, bpp::AbstractParametrizable, and bpp::InvariantMixedDiscreteDistribution.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ setParameters()

◆ setParametersValues()

virtual void bpp::Parametrizable::setParametersValues ( const ParameterList parameters)
pure virtualinherited

Update the parameters from parameters.

parameters must be a subset of all parameters available.

Parameters
parametersA list containing all parameters to update.
Exceptions
ParameterNotFoundExceptionIf a some parameter in params is not in the list.
ConstraintExceptionIf a value in parameters does not match the constraint in the corresponding parameter in the list.

Implemented in bpp::InfinityFunctionWrapper, bpp::FunctionWrapper, bpp::AbstractNumericalDerivative, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().

◆ setParameterValue()

virtual void bpp::Parametrizable::setParameterValue ( const std::string &  name,
double  value 
)
pure virtualinherited

Set the value of parameter with name name to be equal to value.

Parameters
namethe name of the parameter to set.
valueThe value of the parameter.
Exceptions
ParameterNotFoundExceptionIf no parameter in the list has the name name.
ConstraintExceptionIf value does not match the constraint associated to parameter name.

Implemented in bpp::InfinityFunctionWrapper, bpp::FunctionWrapper, bpp::AbstractNumericalDerivative, bpp::ParametrizableAdapter, and bpp::AbstractParametrizable.

Referenced by bpp::Parametrizable::~Parametrizable().


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