bpp-phyl  2.1.0
bpp::G2001 Class Reference

Galtier's 2001 covarion model. More...

#include <Bpp/Phyl/Model/G2001.h>

+ Inheritance diagram for bpp::G2001:
+ Collaboration diagram for bpp::G2001:

List of all members.

Public Member Functions

 G2001 (ReversibleSubstitutionModel *model, DiscreteDistribution *rDist, double nu=1., bool normalizeRateChanges=false)
 Build a new G2001 substitution model.
 G2001 (const G2001 &model)
G2001operator= (const G2001 &model)
virtual ~G2001 ()
G2001clone () const
std::string getName () const
 Get the name of the model.
void fireParameterChanged (const ParameterList &parameters)
 Re-definition of the super-class method to update the rate distribution too.
const DiscreteDistributiongetRateDistribution () const
void setNamespace (const std::string &prefix)
double getRate () const
 Get the rate.
void setRate (double rate)
 Set the rate of the model (must be positive).
void addRateParameter ()
const AlphabetgetAlphabet () const
size_t getNumberOfStates () const
 Get the number of states.
const VdoublegetFrequencies () const
const Matrix< double > & getExchangeabilityMatrix () const
const Matrix< double > & getGenerator () const
const Matrix< double > & getPij_t (double t) const
const Matrix< double > & getdPij_dt (double t) const
const Matrix< double > & getd2Pij_dt2 (double t) const
const VdoublegetEigenValues () const
const VdoublegetIEigenValues () const
bool isDiagonalizable () const
bool isNonSingular () const
const Matrix< double > & getRowLeftEigenVectors () const
const Matrix< double > & getColumnRightEigenVectors () const
double freq (size_t i) const
double Sij (size_t i, size_t j) const
double Qij (size_t i, size_t j) const
double Pij_t (size_t i, size_t j, double t) const
double dPij_dt (size_t i, size_t j, double t) const
double d2Pij_dt2 (size_t i, size_t j, double t) const
double getInitValue (size_t i, int state) const throw (IndexOutOfBoundsException, BadIntException)
void setFreqFromData (const SequenceContainer &data, double pseudoCount=0)
 Set equilibrium frequencies equal to the frequencies estimated from the data.
const std::vector< int > & getAlphabetChars () const
int getAlphabetChar (size_t i) const
 Get the char in the alphabet corresponding to a given state in the model.
std::vector< size_t > getModelStates (int i) const
 Get the state in the model corresponding to a particular char in the alphabet.
const ReversibleSubstitutionModelgetNestedModel () const
size_t getRate (size_t i) const
 Get the rate category corresponding to a particular state in the compound model.
double getScale () const
 Get the scalar product of diagonal elements of the generator and the frequencies vector. If the generator is normalized, then scale=1. Otherwise each element must be multiplied by 1/scale.
void setScale (double scale)
 Set the rate of the generator, defined as the scalar product of diagonal elements of the generator and the frequencies vector.
void enableEigenDecomposition (bool yn)
 Set if eigenValues and Vectors must be computed.
bool enableEigenDecomposition ()
 Tell if eigenValues and Vectors must be computed.
virtual void setFreq (std::map< int, double > &frequencies)
 Set equilibrium frequencies.
virtual const FrequenciesSetgetFrequenciesSet () const
 If the model owns a FrequenciesSet, returns a pointer to it, otherwise return 0.
virtual size_t getNumberOfIndependentParameters () const =0
size_t getNumberOfIndependentParameters () const
virtual void aliasParameters (const std::string &p1, const std::string &p2)=0
void aliasParameters (const std::string &p1, const std::string &p2)
virtual void unaliasParameters (const std::string &p1, const std::string &p2)=0
void unaliasParameters (const std::string &p1, const std::string &p2)
virtual const ParameterListgetIndependentParameters () const =0
const ParameterListgetIndependentParameters () const
virtual std::vector< std::string > getAlias (const std::string &name) const =0
std::vector< std::string > getAlias (const std::string &name) const
virtual bool hasParameter (const std::string &name) const =0
bool hasParameter (const std::string &name) const
virtual const ParameterListgetParameters () const =0
const ParameterListgetParameters () const
virtual const ParametergetParameter (const std::string &name) const =0
const ParametergetParameter (const std::string &name) const
virtual double getParameterValue (const std::string &name) const =0
double getParameterValue (const std::string &name) const
virtual void setAllParametersValues (const ParameterList &parameters)=0
void setAllParametersValues (const ParameterList &parameters)
virtual void setParameterValue (const std::string &name, double value)=0
void setParameterValue (const std::string &name, double value)
virtual void setParametersValues (const ParameterList &parameters)=0
void setParametersValues (const ParameterList &parameters)
virtual bool matchParametersValues (const ParameterList &parameters)=0
bool matchParametersValues (const ParameterList &parameters)
virtual size_t getNumberOfParameters () const =0
size_t getNumberOfParameters () const
virtual std::string getNamespace () const =0
std::string getNamespace () const
virtual std::string getParameterNameWithoutNamespace (const std::string &name) const =0
std::string getParameterNameWithoutNamespace (const std::string &name) const
std::string getFrom (const std::string &name) const

Protected Member Functions

void updateRatesModel ()
 Update the rates vector, generator and equilibrium frequencies.
virtual void updateMatrices ()
void addParameter_ (Parameter *parameter)
void addParameters_ (const ParameterList &parameters)
void deleteParameter_ (size_t index)
void resetParameters_ ()
ParametergetParameter_ (const std::string &name)
ParametergetParameter_ (size_t index)
const ParametergetParameter_ (size_t index) const
ParametergetParameterWithNamespace_ (const std::string &name)
const ParametergetParameterWithNamespace_ (const std::string &name) const
ParameterListgetParameters_ ()

Protected Attributes

ReversibleSubstitutionModelmodel_
size_t nbStates_
size_t nbRates_
RowMatrix< double > ratesGenerator_
std::vector< int > chars_
 The list of supported chars.
RowMatrix< double > generator_
 The generator matrix $Q$ of the model.
RowMatrix< double > exchangeability_
 The exchangeability matrix $S$ of the model.
RowMatrix< double > leftEigenVectors_
 The $U$ matrix made of left eigen vectors (by row).
RowMatrix< double > rightEigenVectors_
 The $U^-1$ matrix made of right eigen vectors (by column).
Vdouble eigenValues_
 The vector of real parts of eigen values.
Vdouble iEigenValues_
 The vector of imaginary parts of the eigen values (zero in case of reversible pmodel).
bool eigenDecompose_
 Tell if the eigen decomposition should be performed.
RowMatrix< double > pijt_
 These ones are for bookkeeping:
RowMatrix< double > dpijt_
RowMatrix< double > d2pijt_
Vdouble freq_
 The vector of equilibrium frequencies.
bool normalizeRateChanges_
std::string nestedPrefix_
Rate generator.

These variables must be initialized in the constructor of the derived class.

RowMatrix< double > rates_
RowMatrix< double > ratesExchangeability_
Vdouble ratesFreq_

Private Attributes

DiscreteDistributionrDist_
std::string nestedRatePrefix_

Detailed Description

Galtier's 2001 covarion model.

This model is a subclass of the so-called Markov-modulated substitution models, with a Jukes-Cantor rate matrix, of parameter $\nu$. the original version uses a discrete $\Gamma$ distribution for rates, but you can use it with virtually any rate distribution.

See also:
MarkovModulatedSubstitutionModel

Galtier N., Maximum-likelihood phylogenetic analysis under a covarion-like model (2001). _Molecular Biology and Evolution_, 18:866-73.

Definition at line 63 of file G2001.h.


Constructor & Destructor Documentation

bpp::G2001::G2001 ( ReversibleSubstitutionModel model,
DiscreteDistribution rDist,
double  nu = 1.,
bool  normalizeRateChanges = false 
) [inline]
bpp::G2001::G2001 ( const G2001 model) [inline]

Definition at line 97 of file G2001.h.

virtual bpp::G2001::~G2001 ( ) [inline, virtual]

Definition at line 111 of file G2001.h.

References rDist_.


Member Function Documentation

void bpp::G2001::addRateParameter ( ) [inline, virtual]

Implements bpp::SubstitutionModel.

Definition at line 146 of file G2001.h.

G2001* bpp::G2001::clone ( ) const [inline, virtual]

Implements bpp::MarkovModulatedSubstitutionModel.

Definition at line 113 of file G2001.h.

References G2001().

double bpp::MarkovModulatedSubstitutionModel::d2Pij_dt2 ( size_t  i,
size_t  j,
double  t 
) const [inline, virtual, inherited]
Returns:
The second order derivative of the probability of change from state i to state j with respect to time t, at time t.
See also:
getd2Pij_dt2(), getStates()

Implements bpp::SubstitutionModel.

Definition at line 220 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::getd2Pij_dt2().

double bpp::MarkovModulatedSubstitutionModel::dPij_dt ( size_t  i,
size_t  j,
double  t 
) const [inline, virtual, inherited]
Returns:
The first order derivative of the probability of change from state i to state j with respect to time t, at time t.
See also:
getdPij_dt(), getStates()

Implements bpp::SubstitutionModel.

Definition at line 219 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::getdPij_dt().

void bpp::MarkovModulatedSubstitutionModel::enableEigenDecomposition ( bool  yn) [inline, virtual, inherited]

Set if eigenValues and Vectors must be computed.

Implements bpp::SubstitutionModel.

Definition at line 280 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::eigenDecompose_.

Tell if eigenValues and Vectors must be computed.

Implements bpp::SubstitutionModel.

Definition at line 282 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::eigenDecompose_.

void bpp::G2001::fireParameterChanged ( const ParameterList parameters) [inline, virtual]

Re-definition of the super-class method to update the rate distribution too.

Parameters:
parametersThe parameters that have been modified.

Reimplemented from bpp::MarkovModulatedSubstitutionModel.

Definition at line 123 of file G2001.h.

References bpp::DiscreteDistribution::matchParametersValues(), and rDist_.

double bpp::MarkovModulatedSubstitutionModel::freq ( size_t  i) const [inline, virtual, inherited]
Returns:
Equilibrium frequency associated to character i.
See also:
getFrequencies(), getStates()

Implements bpp::SubstitutionModel.

Definition at line 214 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::freq_.

const Alphabet* bpp::MarkovModulatedSubstitutionModel::getAlphabet ( ) const [inline, virtual, inherited]
Returns:
Get the alphabet associated to this model.

Implements bpp::SubstitutionModel.

Definition at line 191 of file MarkovModulatedSubstitutionModel.h.

References bpp::SubstitutionModel::getAlphabet(), and bpp::MarkovModulatedSubstitutionModel::model_.

int bpp::MarkovModulatedSubstitutionModel::getAlphabetChar ( size_t  i) const [inline, virtual, inherited]

Get the char in the alphabet corresponding to a given state in the model.

In most cases, this method will return i.

Parameters:
iThe index of the state.
Returns:
The corresponding state in the alphabet.
See also:
MarkovModulatedSubstitutionModel
getStates()

Implements bpp::SubstitutionModel.

Definition at line 235 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::chars_.

const std::vector<int>& bpp::MarkovModulatedSubstitutionModel::getAlphabetChars ( ) const [inline, virtual, inherited]
Returns:
The supported states of the model, as a vector of int codes.
See also:
Alphabet

Implements bpp::SubstitutionModel.

Definition at line 230 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::chars_.

const Matrix<double>& bpp::MarkovModulatedSubstitutionModel::getColumnRightEigenVectors ( ) const [inline, virtual, inherited]
Returns:
A matrix with right eigen vectors. Each column in the matrix stands for an eigen vector.

Implements bpp::SubstitutionModel.

Definition at line 212 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::rightEigenVectors_.

const Matrix< double > & MarkovModulatedSubstitutionModel::getdPij_dt ( double  t) const [virtual, inherited]
const Vdouble& bpp::MarkovModulatedSubstitutionModel::getEigenValues ( ) const [inline, virtual, inherited]
Returns:
A vector with all real parts of the eigen values of the generator of this model;

Implements bpp::SubstitutionModel.

Definition at line 205 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::eigenValues_.

const Matrix<double>& bpp::MarkovModulatedSubstitutionModel::getExchangeabilityMatrix ( ) const [inline, virtual, inherited]
Returns:
The matrix of exchangeability terms. It is recommended that exchangeability matrix be normalized so that the normalized generator be obtained directly by the dot product $S . \pi$.

Implements bpp::SubstitutionModel.

Definition at line 197 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::exchangeability_.

const Vdouble& bpp::MarkovModulatedSubstitutionModel::getFrequencies ( ) const [inline, virtual, inherited]
Returns:
A vector of all equilibrium frequencies.
See also:
freq()

Implements bpp::SubstitutionModel.

Definition at line 195 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::freq_.

const Matrix<double>& bpp::MarkovModulatedSubstitutionModel::getGenerator ( ) const [inline, virtual, inherited]
Returns:
The normalized Markov generator matrix, i.e. all normalized rates of changes from state i to state j. The generator is normalized so that (i) $ \forall i; \sum_j Q_{i,j} = 0 $, meaning that $ $ \forall i; Q_{i,i} = -\sum_{j \neq i}Q_{i,j}$, and (ii) $ \sum_i Q_{i,i} \times \pi_i = -1$. This means that, under normalization, the mean rate of replacement at equilibrium is 1 and that time $t$ are measured in units of expected number of changes per site. Additionnaly, the rate_ attibute provides the possibility to increase or decrease this mean rate.

See Kosiol and Goldman (2005), Molecular Biology And Evolution 22(2) 193-9.

See also:
Qij()

Implements bpp::SubstitutionModel.

Definition at line 199 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::generator_.

const Vdouble& bpp::MarkovModulatedSubstitutionModel::getIEigenValues ( ) const [inline, virtual, inherited]
Returns:
A vector with all imaginary parts of the eigen values of the generator of this model;

Implements bpp::SubstitutionModel.

Definition at line 206 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::iEigenValues_.

double MarkovModulatedSubstitutionModel::getInitValue ( size_t  i,
int  state 
) const throw (IndexOutOfBoundsException, BadIntException) [virtual, inherited]

This method is used to initialize likelihoods in reccursions. It typically sends 1 if i = state, 0 otherwise, where i is one of the possible states of the alphabet allowed in the model and state is the observed state in the considered sequence/site.

Parameters:
ithe index of the state in the model.
stateAn observed state in the sequence/site.
Returns:
1 or 0 depending if the two states are compatible.
Exceptions:
IndexOutOfBoundsExceptionif array position is out of range.
BadIntExceptionif states are not allowed in the associated alphabet.
See also:
getStates();

Implements bpp::SubstitutionModel.

Definition at line 204 of file MarkovModulatedSubstitutionModel.cpp.

References bpp::Alphabet::getAlias(), and bpp::BadIntException::getAlphabet().

std::vector<size_t> bpp::MarkovModulatedSubstitutionModel::getModelStates ( int  i) const [inline, virtual, inherited]

Get the state in the model corresponding to a particular char in the alphabet.

Parameters:
iThe alphabet char to check.
Returns:
A vector of indices of model states.

Implements bpp::SubstitutionModel.

Definition at line 240 of file MarkovModulatedSubstitutionModel.h.

References bpp::SubstitutionModel::getModelStates(), bpp::MarkovModulatedSubstitutionModel::model_, bpp::MarkovModulatedSubstitutionModel::nbRates_, and bpp::MarkovModulatedSubstitutionModel::nbStates_.

std::string bpp::G2001::getName ( ) const [inline, virtual]

Get the name of the model.

Returns:
The name of this model.

Implements bpp::SubstitutionModel.

Definition at line 116 of file G2001.h.

size_t bpp::MarkovModulatedSubstitutionModel::getNumberOfStates ( ) const [inline, virtual, inherited]

Get the number of states.

For most models, this equals the size of the alphabet.

Returns:
The number of different states in the model.

Implements bpp::SubstitutionModel.

Definition at line 193 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::nbRates_, and bpp::MarkovModulatedSubstitutionModel::nbStates_.

double bpp::G2001::getRate ( ) const [inline, virtual]

Get the rate.

Reimplemented from bpp::MarkovModulatedSubstitutionModel.

Definition at line 142 of file G2001.h.

size_t bpp::MarkovModulatedSubstitutionModel::getRate ( size_t  i) const [inline, inherited]

Get the rate category corresponding to a particular state in the compound model.

Parameters:
iThe state.
Returns:
The corresponding rate category.
See also:
getState;

Definition at line 259 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::nbStates_.

Returns:
The rate distribution associated to this instance.

Definition at line 132 of file G2001.h.

References rDist_.

Referenced by bpp::BppOSubstitutionModelFormat::write().

const Matrix<double>& bpp::MarkovModulatedSubstitutionModel::getRowLeftEigenVectors ( ) const [inline, virtual, inherited]
Returns:
A matrix with left eigen vectors. Each row in the matrix stands for an eigen vector.

Implements bpp::SubstitutionModel.

Definition at line 211 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::leftEigenVectors_.

double bpp::MarkovModulatedSubstitutionModel::getScale ( ) const [inline, virtual, inherited]

Get the scalar product of diagonal elements of the generator and the frequencies vector. If the generator is normalized, then scale=1. Otherwise each element must be multiplied by 1/scale.

Returns:
Minus the scalar product of diagonal elements and the frequencies vector.

Implements bpp::SubstitutionModel.

Definition at line 268 of file MarkovModulatedSubstitutionModel.h.

References bpp::MatrixTools::diag(), bpp::MarkovModulatedSubstitutionModel::freq_, and bpp::MarkovModulatedSubstitutionModel::generator_.

bool bpp::MarkovModulatedSubstitutionModel::isDiagonalizable ( ) const [inline, virtual, inherited]
Returns:
True if the model is diagonalizable in R.

Implements bpp::SubstitutionModel.

Definition at line 208 of file MarkovModulatedSubstitutionModel.h.

bool bpp::MarkovModulatedSubstitutionModel::isNonSingular ( ) const [inline, virtual, inherited]
Returns:
True is the model is non-singular.

Implements bpp::SubstitutionModel.

Definition at line 209 of file MarkovModulatedSubstitutionModel.h.

G2001& bpp::G2001::operator= ( const G2001 model) [inline]

Definition at line 103 of file G2001.h.

References bpp::DiscreteDistribution::clone(), nestedRatePrefix_, and rDist_.

double bpp::MarkovModulatedSubstitutionModel::Pij_t ( size_t  i,
size_t  j,
double  t 
) const [inline, virtual, inherited]
Returns:
The probability of change from state i to state j during time t.
See also:
getPij_t(), getStates()

Implements bpp::SubstitutionModel.

Definition at line 218 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::getPij_t().

double bpp::MarkovModulatedSubstitutionModel::Qij ( size_t  i,
size_t  j 
) const [inline, virtual, inherited]
Returns:
The rate in the generator of change from state i to state j.
See also:
getStates();

Implements bpp::SubstitutionModel.

Definition at line 216 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::generator_.

void bpp::MarkovModulatedSubstitutionModel::setFreqFromData ( const SequenceContainer data,
double  pseudoCount = 0 
) [inline, virtual, inherited]

Set equilibrium frequencies equal to the frequencies estimated from the data.

Parameters:
dataThe sequences to use.
pseudoCountA quantity $\psi$ to add to adjust the observed values in order to prevent issues due to missing states on small data set. The corrected frequencies shall be computed as

\[ \pi_i = \frac{n_i+\psi}{\sum_j (f_j+\psi)} \]

Implements bpp::SubstitutionModel.

Definition at line 224 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::model_, bpp::SubstitutionModel::setFreqFromData(), and bpp::MarkovModulatedSubstitutionModel::updateMatrices().

void bpp::G2001::setNamespace ( const std::string &  prefix) [inline, virtual]
void bpp::G2001::setRate ( double  rate) [inline, virtual]

Set the rate of the model (must be positive).

Parameters:
ratemust be positive.

Reimplemented from bpp::MarkovModulatedSubstitutionModel.

Definition at line 144 of file G2001.h.

void bpp::MarkovModulatedSubstitutionModel::setScale ( double  scale) [inline, virtual, inherited]

Set the rate of the generator, defined as the scalar product of diagonal elements of the generator and the frequencies vector.

When the generator is normalized, scale=1. Otherwise each element is multiplied such that the correct scale is set.

Implements bpp::SubstitutionModel.

Definition at line 275 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::model_, bpp::SubstitutionModel::setScale(), and bpp::MarkovModulatedSubstitutionModel::updateMatrices().

double bpp::MarkovModulatedSubstitutionModel::Sij ( size_t  i,
size_t  j 
) const [inline, virtual, inherited]
Returns:
The exchangeability between state i and state j.

By definition Sij(i,j) = Sij(j,i).

Implements bpp::SubstitutionModel.

Definition at line 215 of file MarkovModulatedSubstitutionModel.h.

References bpp::MarkovModulatedSubstitutionModel::exchangeability_.

void MarkovModulatedSubstitutionModel::updateMatrices ( ) [protected, virtual, inherited]

Definition at line 107 of file MarkovModulatedSubstitutionModel.cpp.

References bpp::MatrixTools::add(), bpp::MarkovModulatedSubstitutionModel::chars_, bpp::MarkovModulatedSubstitutionModel::d2pijt_, bpp::MatrixTools::diag(), bpp::MarkovModulatedSubstitutionModel::dpijt_, bpp::MarkovModulatedSubstitutionModel::eigenValues_, bpp::MarkovModulatedSubstitutionModel::exchangeability_, bpp::MarkovModulatedSubstitutionModel::freq_, bpp::MarkovModulatedSubstitutionModel::generator_, bpp::SubstitutionModel::getAlphabetChars(), bpp::SubstitutionModel::getColumnRightEigenVectors(), bpp::SubstitutionModel::getEigenValues(), bpp::SubstitutionModel::getExchangeabilityMatrix(), bpp::SubstitutionModel::getFrequencies(), bpp::SubstitutionModel::getGenerator(), bpp::RowMatrix< Scalar >::getNumberOfColumns(), bpp::SubstitutionModel::getNumberOfStates(), bpp::EigenValue< Real >::getRealEigenValues(), bpp::EigenValue< Real >::getV(), bpp::MarkovModulatedSubstitutionModel::iEigenValues_, bpp::MatrixTools::inv(), bpp::VectorTools::kroneckerMult(), bpp::MatrixTools::kroneckerMult(), bpp::MarkovModulatedSubstitutionModel::leftEigenVectors_, bpp::MarkovModulatedSubstitutionModel::model_, bpp::MatrixTools::mult(), bpp::MarkovModulatedSubstitutionModel::nbRates_, bpp::MarkovModulatedSubstitutionModel::nbStates_, bpp::MarkovModulatedSubstitutionModel::normalizeRateChanges_, bpp::MarkovModulatedSubstitutionModel::pijt_, bpp::MarkovModulatedSubstitutionModel::rates_, bpp::MarkovModulatedSubstitutionModel::ratesExchangeability_, bpp::MarkovModulatedSubstitutionModel::ratesFreq_, bpp::MarkovModulatedSubstitutionModel::ratesGenerator_, bpp::VectorTools::rep(), bpp::RowMatrix< Scalar >::resize(), bpp::MarkovModulatedSubstitutionModel::rightEigenVectors_, and bpp::MatrixTools::scale().

Referenced by bpp::MarkovModulatedSubstitutionModel::fireParameterChanged(), G2001(), bpp::MarkovModulatedSubstitutionModel::setFreqFromData(), bpp::MarkovModulatedSubstitutionModel::setScale(), and bpp::TS98::TS98().

void bpp::G2001::updateRatesModel ( ) [inline, protected, virtual]

Update the rates vector, generator and equilibrium frequencies.

This method must be implemented by the derived class. It is called by the fireParameterChanged() method.

Implements bpp::MarkovModulatedSubstitutionModel.

Definition at line 149 of file G2001.h.

References bpp::DiscreteDistribution::getCategory(), bpp::AbstractParameterAliasable::getParameterValue(), bpp::MarkovModulatedSubstitutionModel::nbRates_, bpp::MarkovModulatedSubstitutionModel::rates_, bpp::MarkovModulatedSubstitutionModel::ratesExchangeability_, and rDist_.

Referenced by G2001().


Member Data Documentation

std::string bpp::G2001::nestedRatePrefix_ [private]

Definition at line 69 of file G2001.h.

Referenced by G2001(), operator=(), and setNamespace().


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Friends