|
bpp-phyl
2.1.0
|
Partial implementation of the Markov-modulated class of substitution models. More...
#include <Bpp/Phyl/Model/MarkovModulatedSubstitutionModel.h>
Inheritance diagram for bpp::MarkovModulatedSubstitutionModel:
Collaboration diagram for bpp::MarkovModulatedSubstitutionModel:Public Member Functions | |
| MarkovModulatedSubstitutionModel (ReversibleSubstitutionModel *model, bool normalizeRateChanges, const std::string &prefix) | |
| Build a new MarkovModulatedSubstitutionModel object. More... | |
| MarkovModulatedSubstitutionModel (const MarkovModulatedSubstitutionModel &model) | |
| MarkovModulatedSubstitutionModel & | operator= (const MarkovModulatedSubstitutionModel &model) |
| virtual | ~MarkovModulatedSubstitutionModel () |
| MarkovModulatedSubstitutionModel * | clone () const =0 |
| const Alphabet * | getAlphabet () const |
| size_t | getNumberOfStates () const |
| Get the number of states. More... | |
| const Vdouble & | getFrequencies () 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 Vdouble & | getEigenValues () const |
| const Vdouble & | getIEigenValues () 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. More... | |
| 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. More... | |
| std::vector< size_t > | getModelStates (int i) const |
| Get the state in the model corresponding to a particular char in the alphabet. More... | |
| const ReversibleSubstitutionModel * | getNestedModel () const |
| size_t | getRate (size_t i) const |
| Get the rate category corresponding to a particular state in the compound model. More... | |
| double | getRate () const |
| Get the rate. More... | |
| void | setRate (double rate) |
| Set the rate of the model (must be positive). More... | |
| 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. More... | |
| 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. More... | |
| void | enableEigenDecomposition (bool yn) |
| Set if eigenValues and Vectors must be computed. More... | |
| bool | enableEigenDecomposition () |
| Tell if eigenValues and Vectors must be computed. More... | |
| virtual void | fireParameterChanged (const ParameterList ¶meters) |
| Tells the model that a parameter value has changed. More... | |
| void | setNamespace (const std::string &prefix) |
| virtual std::string | getName () const =0 |
| Get the name of the model. More... | |
| virtual void | addRateParameter ()=0 |
| virtual void | setFreq (std::map< int, double > &frequencies) |
| Set equilibrium frequencies. More... | |
| virtual const FrequenciesSet * | getFrequenciesSet () const |
| If the model owns a FrequenciesSet, returns a pointer to it, otherwise return 0. More... | |
| virtual size_t | getNumberOfIndependentParameters () const =0 |
| virtual void | aliasParameters (const std::string &p1, const std::string &p2)=0 |
| virtual void | unaliasParameters (const std::string &p1, const std::string &p2)=0 |
| virtual const ParameterList & | getIndependentParameters () const =0 |
| virtual std::vector< std::string > | getAlias (const std::string &name) const =0 |
| const ParameterList & | getIndependentParameters () const |
| size_t | getNumberOfIndependentParameters () const |
| void | aliasParameters (const std::string &p1, const std::string &p2) |
| void | unaliasParameters (const std::string &p1, const std::string &p2) |
| std::vector< std::string > | getAlias (const std::string &name) const |
| bool | hasParameter (const std::string &name) const |
| const ParameterList & | getParameters () const |
| const Parameter & | getParameter (const std::string &name) const |
| double | getParameterValue (const std::string &name) const |
| void | setAllParametersValues (const ParameterList ¶meters) |
| void | setParameterValue (const std::string &name, double value) |
| void | setParametersValues (const ParameterList ¶meters) |
| bool | matchParametersValues (const ParameterList ¶meters) |
| size_t | getNumberOfParameters () const |
| std::string | getNamespace () const |
| std::string | getParameterNameWithoutNamespace (const std::string &name) const |
Protected Member Functions | |
| virtual void | updateMatrices () |
| virtual void | updateRatesModel ()=0 |
| Update the rates vector, generator and equilibrium frequencies. More... | |
| void | addParameter_ (Parameter *parameter) |
| void | addParameters_ (const ParameterList ¶meters) |
| void | deleteParameter_ (size_t index) |
| void | resetParameters_ () |
| Parameter & | getParameter_ (const std::string &name) |
| Parameter & | getParameter_ (size_t index) |
| const Parameter & | getParameter_ (size_t index) const |
| Parameter & | getParameterWithNamespace_ (const std::string &name) |
| const Parameter & | getParameterWithNamespace_ (const std::string &name) const |
| ParameterList & | getParameters_ () |
Protected Attributes | |
| ReversibleSubstitutionModel * | model_ |
| size_t | nbStates_ |
| size_t | nbRates_ |
| RowMatrix< double > | ratesGenerator_ |
| std::vector< int > | chars_ |
| The list of supported chars. More... | |
| RowMatrix< double > | generator_ |
The generator matrix of the model. More... | |
| RowMatrix< double > | exchangeability_ |
The exchangeability matrix of the model. More... | |
| RowMatrix< double > | leftEigenVectors_ |
The matrix made of left eigen vectors (by row). More... | |
| RowMatrix< double > | rightEigenVectors_ |
The matrix made of right eigen vectors (by column). More... | |
| Vdouble | eigenValues_ |
| The vector of real parts of eigen values. More... | |
| Vdouble | iEigenValues_ |
| The vector of imaginary parts of the eigen values (zero in case of reversible pmodel). More... | |
| bool | eigenDecompose_ |
| Tell if the eigen decomposition should be performed. More... | |
| RowMatrix< double > | pijt_ |
| These ones are for bookkeeping: More... | |
| RowMatrix< double > | dpijt_ |
| RowMatrix< double > | d2pijt_ |
| Vdouble | freq_ |
| The vector of equilibrium frequencies. More... | |
| 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_ |
Partial implementation of the Markov-modulated class of substitution models.
This class wraps a substitution model and provide a matrix describing rate changes. The rate matrix must be initialized by derived classes of this class. Using these matrices, the diagonalization procedure of Galtier and Jean-Marie is used.
Such models can be described using two matrices: a substitution matrix,
, with size
, which is a "standard" substitution model of any alphabet type, and a rate matrix
of size
. The generator of the markov-modulated model,
can be written using Kronecker matrix operands:
where
is the diagonal matrix of all rates, and
is the identity matrix of size
.
This generator is normalized so that branch lengths are measured in unit of mean number of substitutions per site, where susbstitution here means "change of alphabet state". Rate changes are not counted.
Galtier N. and Jean-Marie A., Markov-modulated Markov chains and the covarion process of molecular evolution (2004). Journal of Computational Biology, 11:727-33.
Definition at line 75 of file MarkovModulatedSubstitutionModel.h.
|
inline |
Build a new MarkovModulatedSubstitutionModel object.
| model | The substitution model to use. Can be of any alphabet type, and will be owned by this instance. |
| normalizeRateChanges | Tells if the branch lengths must be computed in terms of rate and state |
| prefix | The parameter namespace to be forwarded to the AbstractParametrizable constructor. changes instead of state change only. NB: In most cases, this parameter should be set to false. |
Definition at line 164 of file MarkovModulatedSubstitutionModel.h.
References bpp::AbstractParameterAliasable::addParameters_(), model_, and nestedPrefix_.
| MarkovModulatedSubstitutionModel::MarkovModulatedSubstitutionModel | ( | const MarkovModulatedSubstitutionModel & | model | ) |
Definition at line 51 of file MarkovModulatedSubstitutionModel.cpp.
|
inlinevirtual |
Definition at line 180 of file MarkovModulatedSubstitutionModel.h.
References model_.
|
pure virtualinherited |
Implemented in bpp::AbstractSubstitutionModel, bpp::G2001, bpp::AbstractBiblioSubstitutionModel, and bpp::TS98.
Referenced by bpp::AbstractBiblioSubstitutionModel::addRateParameter().
|
pure virtual |
Implements bpp::ReversibleSubstitutionModel.
Implemented in bpp::G2001, and bpp::TS98.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 220 of file MarkovModulatedSubstitutionModel.h.
References getd2Pij_dt2().
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 219 of file MarkovModulatedSubstitutionModel.h.
References getdPij_dt().
|
inlinevirtual |
Set if eigenValues and Vectors must be computed.
Implements bpp::SubstitutionModel.
Definition at line 280 of file MarkovModulatedSubstitutionModel.h.
References eigenDecompose_.
|
inlinevirtual |
Tell if eigenValues and Vectors must be computed.
Implements bpp::SubstitutionModel.
Definition at line 282 of file MarkovModulatedSubstitutionModel.h.
References eigenDecompose_.
|
inlinevirtual |
Tells the model that a parameter value has changed.
This updates the matrices consequently.
Reimplemented from bpp::AbstractParameterAliasable.
Reimplemented in bpp::G2001.
Definition at line 289 of file MarkovModulatedSubstitutionModel.h.
References bpp::AbstractParameterAliasable::fireParameterChanged(), model_, updateMatrices(), and updateRatesModel().
Referenced by bpp::G2001::fireParameterChanged().
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 214 of file MarkovModulatedSubstitutionModel.h.
References freq_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 191 of file MarkovModulatedSubstitutionModel.h.
References model_.
|
inlinevirtual |
Get the char in the alphabet corresponding to a given state in the model.
In most cases, this method will return i.
| i | The index of the state. |
Implements bpp::SubstitutionModel.
Definition at line 235 of file MarkovModulatedSubstitutionModel.h.
References chars_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 230 of file MarkovModulatedSubstitutionModel.h.
References chars_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 212 of file MarkovModulatedSubstitutionModel.h.
References rightEigenVectors_.
|
virtual |
Implements bpp::SubstitutionModel.
Definition at line 196 of file MarkovModulatedSubstitutionModel.cpp.
References d2pijt_, d2pijt_, bpp::VectorTools::exp(), leftEigenVectors_, bpp::MatrixTools::mult(), and bpp::NumTools::sqr().
Referenced by d2Pij_dt2().
|
virtual |
Implements bpp::SubstitutionModel.
Definition at line 190 of file MarkovModulatedSubstitutionModel.cpp.
References dpijt_, dpijt_, eigenValues_, bpp::VectorTools::exp(), leftEigenVectors_, and bpp::MatrixTools::mult().
Referenced by dPij_dt().
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 205 of file MarkovModulatedSubstitutionModel.h.
References eigenValues_.
|
inlinevirtual |
. Implements bpp::SubstitutionModel.
Definition at line 197 of file MarkovModulatedSubstitutionModel.h.
References exchangeability_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 195 of file MarkovModulatedSubstitutionModel.h.
References freq_.
|
inlinevirtualinherited |
If the model owns a FrequenciesSet, returns a pointer to it, otherwise return 0.
Reimplemented in bpp::JCprot, bpp::AbstractBiblioSubstitutionModel, bpp::UserProteinSubstitutionModel, bpp::WAG01, bpp::DSO78, bpp::JTT92, bpp::LG08, bpp::AbstractCodonPhaseFrequenciesSubstitutionModel, and bpp::AbstractCodonFrequenciesSubstitutionModel.
Definition at line 463 of file SubstitutionModel.h.
Referenced by bpp::AbstractBiblioSubstitutionModel::getFrequenciesSet(), and bpp::BppOSubstitutionModelFormat::write().
|
inlinevirtual |
, meaning that $
, and (ii)
. This means that, under normalization, the mean rate of replacement at equilibrium is 1 and that time
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.
Implements bpp::SubstitutionModel.
Definition at line 199 of file MarkovModulatedSubstitutionModel.h.
References generator_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 206 of file MarkovModulatedSubstitutionModel.h.
References iEigenValues_.
|
virtual |
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.
| i | the index of the state in the model. |
| state | An observed state in the sequence/site. |
| IndexOutOfBoundsException | if array position is out of range. |
| BadIntException | if states are not allowed in the associated alphabet. |
Implements bpp::SubstitutionModel.
Definition at line 204 of file MarkovModulatedSubstitutionModel.cpp.
References bpp::AlphabetException::getAlphabet().
|
inlinevirtual |
Get the state in the model corresponding to a particular char in the alphabet.
| i | The alphabet char to check. |
Implements bpp::SubstitutionModel.
Definition at line 240 of file MarkovModulatedSubstitutionModel.h.
|
pure virtualinherited |
Get the name of the model.
Implemented in bpp::YpR_Gen, bpp::YpR_Sym, bpp::F84, bpp::HKY85, bpp::JCprot, bpp::T92, bpp::K80, bpp::RN95, bpp::CodonDistanceFrequenciesSubstitutionModel, bpp::GTR, bpp::TN93, bpp::RE08, bpp::MixtureOfSubstitutionModels, bpp::JCnuc, bpp::CodonDistancePhaseFrequenciesSubstitutionModel, bpp::CodonDistanceFitnessPhaseFrequenciesSubstitutionModel, bpp::RN95s, bpp::BinarySubstitutionModel, bpp::CodonDistanceSubstitutionModel, bpp::UserProteinSubstitutionModel, bpp::MixtureOfASubstitutionModel, bpp::LLG08_EX3, bpp::WordSubstitutionModel, bpp::LLG08_EHO, bpp::LLG08_UL3, bpp::WAG01, bpp::SSR, bpp::L95, bpp::LGL08_CAT, bpp::LLG08_EX2, bpp::LLG08_UL2, bpp::DSO78, bpp::JTT92, bpp::gBGC, bpp::CodonRateFrequenciesSubstitutionModel, bpp::G2001, bpp::LG08, bpp::YNGKP_M1, bpp::YNGKP_M8, bpp::TS98, bpp::YNGKP_M7, bpp::GY94, bpp::YNGKP_M2, bpp::YNGKP_M3, bpp::TripletSubstitutionModel, bpp::YN98, bpp::CodonRateSubstitutionModel, bpp::MG94, bpp::Coala, bpp::LLG08_EX3::EmbeddedModel, bpp::LLG08_EHO::EmbeddedModel, bpp::LLG08_UL3::EmbeddedModel, bpp::LGL08_CAT::EmbeddedModel, bpp::LLG08_EX2::EmbeddedModel, and bpp::LLG08_UL2::EmbeddedModel.
Referenced by bpp::AbstractCodonFitnessSubstitutionModel::AbstractCodonFitnessSubstitutionModel(), bpp::AbstractSubstitutionModel::fireParameterChanged(), bpp::gBGC::getName(), bpp::MixtureOfSubstitutionModels::getSubmodelNumbers(), bpp::BppOSubstitutionModelFormat::readMixed_(), bpp::AbstractWordSubstitutionModel::updateMatrices(), bpp::AbstractBiblioSubstitutionModel::updateMatrices(), and bpp::BppOSubstitutionModelFormat::write().
|
inline |
Definition at line 250 of file MarkovModulatedSubstitutionModel.h.
References model_.
Referenced by bpp::BppOSubstitutionModelFormat::write().
|
inlinevirtual |
Get the number of states.
For most models, this equals the size of the alphabet.
Implements bpp::SubstitutionModel.
Definition at line 193 of file MarkovModulatedSubstitutionModel.h.
|
virtual |
Implements bpp::SubstitutionModel.
Definition at line 181 of file MarkovModulatedSubstitutionModel.cpp.
References bpp::VectorTools::exp(), leftEigenVectors_, bpp::MatrixTools::mult(), nbRates_, nbStates_, pijt_, pijt_, and pijt_.
Referenced by Pij_t().
|
inline |
Get the rate category corresponding to a particular state in the compound model.
| i | The state. |
Definition at line 259 of file MarkovModulatedSubstitutionModel.h.
References nbStates_.
|
inlinevirtual |
Get the rate.
Implements bpp::SubstitutionModel.
Reimplemented in bpp::TS98.
Definition at line 264 of file MarkovModulatedSubstitutionModel.h.
References model_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 211 of file MarkovModulatedSubstitutionModel.h.
References leftEigenVectors_.
|
inlinevirtual |
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.
Implements bpp::SubstitutionModel.
Definition at line 268 of file MarkovModulatedSubstitutionModel.h.
References bpp::MatrixTools::diag(), and freq_.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 208 of file MarkovModulatedSubstitutionModel.h.
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 209 of file MarkovModulatedSubstitutionModel.h.
| MarkovModulatedSubstitutionModel & MarkovModulatedSubstitutionModel::operator= | ( | const MarkovModulatedSubstitutionModel & | model | ) |
Definition at line 77 of file MarkovModulatedSubstitutionModel.cpp.
References chars_, chars_, d2pijt_, d2pijt_, dpijt_, dpijt_, eigenDecompose_, eigenDecompose_, eigenValues_, eigenValues_, exchangeability_, exchangeability_, freq_, freq_, generator_, generator_, iEigenValues_, iEigenValues_, leftEigenVectors_, leftEigenVectors_, model_, model_, nbRates_, nbRates_, nbStates_, nbStates_, nestedPrefix_, nestedPrefix_, normalizeRateChanges_, normalizeRateChanges_, pijt_, pijt_, rates_, rates_, ratesExchangeability_, ratesExchangeability_, ratesFreq_, ratesFreq_, ratesGenerator_, ratesGenerator_, rightEigenVectors_, and rightEigenVectors_.
Referenced by bpp::G2001::operator=().
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 218 of file MarkovModulatedSubstitutionModel.h.
References getPij_t().
|
inlinevirtual |
Implements bpp::SubstitutionModel.
Definition at line 216 of file MarkovModulatedSubstitutionModel.h.
References generator_.
|
inlinevirtualinherited |
Set equilibrium frequencies.
| frequencies | The map of the frequencies to use. |
Reimplemented in bpp::AbstractSubstitutionModel, bpp::F84, bpp::HKY85, bpp::MixtureOfSubstitutionModels, bpp::T92, bpp::AbstractWordSubstitutionModel, bpp::GTR, bpp::CodonDistanceFrequenciesSubstitutionModel, bpp::RN95, bpp::TN93, bpp::CodonDistancePhaseFrequenciesSubstitutionModel, bpp::RN95s, bpp::CodonDistanceFitnessPhaseFrequenciesSubstitutionModel, bpp::MixtureOfASubstitutionModel, bpp::AbstractBiblioSubstitutionModel, bpp::BinarySubstitutionModel, bpp::SSR, bpp::L95, bpp::CodonRateFrequenciesSubstitutionModel, bpp::AbstractCodonPhaseFrequenciesSubstitutionModel, bpp::AbstractCodonFrequenciesSubstitutionModel, and bpp::AbstractCodonFitnessSubstitutionModel.
Definition at line 455 of file SubstitutionModel.h.
Referenced by bpp::AbstractBiblioSubstitutionModel::setFreq().
|
inlinevirtual |
Set equilibrium frequencies equal to the frequencies estimated from the data.
| data | The sequences to use. |
| pseudoCount | A quantity 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
|
Implements bpp::SubstitutionModel.
Definition at line 224 of file MarkovModulatedSubstitutionModel.h.
References model_, and updateMatrices().
| void MarkovModulatedSubstitutionModel::setNamespace | ( | const std::string & | prefix | ) |
Definition at line 221 of file MarkovModulatedSubstitutionModel.cpp.
References model_, nestedPrefix_, and bpp::AbstractParameterAliasable::setNamespace().
Referenced by bpp::G2001::setNamespace().
|
inlinevirtual |
Set the rate of the model (must be positive).
| rate | must be positive. |
Implements bpp::SubstitutionModel.
Reimplemented in bpp::TS98.
Definition at line 266 of file MarkovModulatedSubstitutionModel.h.
References model_.
|
inlinevirtual |
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 model_, and updateMatrices().
|
inlinevirtual |
By definition Sij(i,j) = Sij(j,i).
Implements bpp::SubstitutionModel.
Definition at line 215 of file MarkovModulatedSubstitutionModel.h.
References exchangeability_.
|
protectedvirtual |
Definition at line 107 of file MarkovModulatedSubstitutionModel.cpp.
References bpp::MatrixTools::add(), bpp::MatrixTools::add(), bpp::MatrixTools::add(), chars_, d2pijt_, bpp::MatrixTools::diag(), bpp::MatrixTools::diag(), bpp::MatrixTools::diag(), bpp::MatrixTools::diag(), dpijt_, eigenValues_, eigenValues_, exchangeability_, freq_, freq_, generator_, bpp::EigenValue< Real >::getRealEigenValues(), bpp::EigenValue< Real >::getV(), iEigenValues_, bpp::MatrixTools::inv(), bpp::MatrixTools::kroneckerMult(), bpp::MatrixTools::kroneckerMult(), bpp::MatrixTools::kroneckerMult(), bpp::VectorTools::kroneckerMult(), bpp::MatrixTools::kroneckerMult(), leftEigenVectors_, model_, model_, model_, model_, model_, model_, model_, bpp::MatrixTools::mult(), bpp::MatrixTools::mult(), nbRates_, nbRates_, nbRates_, nbRates_, nbRates_, nbStates_, nbStates_, nbStates_, nbStates_, normalizeRateChanges_, pijt_, rates_, rates_, ratesFreq_, ratesGenerator_, ratesGenerator_, bpp::VectorTools::rep(), rightEigenVectors_, rightEigenVectors_, bpp::MatrixTools::scale(), bpp::MatrixTools::scale(), and bpp::MatrixTools::scale().
Referenced by fireParameterChanged(), bpp::G2001::G2001(), setFreqFromData(), setScale(), and bpp::TS98::TS98().
|
protectedpure 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.
Implemented in bpp::G2001, and bpp::TS98.
Referenced by fireParameterChanged().
|
protected |
The list of supported chars.
Definition at line 100 of file MarkovModulatedSubstitutionModel.h.
Referenced by getAlphabetChar(), getAlphabetChars(), operator=(), operator=(), and updateMatrices().
|
mutableprotected |
Definition at line 143 of file MarkovModulatedSubstitutionModel.h.
Referenced by getd2Pij_dt2(), getd2Pij_dt2(), operator=(), operator=(), and updateMatrices().
|
mutableprotected |
Definition at line 142 of file MarkovModulatedSubstitutionModel.h.
Referenced by getdPij_dt(), getdPij_dt(), operator=(), operator=(), and updateMatrices().
|
protected |
Tell if the eigen decomposition should be performed.
Definition at line 136 of file MarkovModulatedSubstitutionModel.h.
Referenced by enableEigenDecomposition(), enableEigenDecomposition(), operator=(), and operator=().
|
protected |
The vector of real parts of eigen values.
Definition at line 125 of file MarkovModulatedSubstitutionModel.h.
Referenced by getd2Pij_dt2(), getd2Pij_dt2(), getdPij_dt(), getdPij_dt(), getEigenValues(), getPij_t(), operator=(), operator=(), updateMatrices(), and updateMatrices().
|
protected |
The exchangeability matrix
of the model.
Definition at line 110 of file MarkovModulatedSubstitutionModel.h.
Referenced by getExchangeabilityMatrix(), operator=(), operator=(), Sij(), updateMatrices(), updateMatrices(), and updateMatrices().
|
protected |
The vector of equilibrium frequencies.
Definition at line 148 of file MarkovModulatedSubstitutionModel.h.
Referenced by freq(), getFrequencies(), getScale(), operator=(), operator=(), updateMatrices(), and updateMatrices().
|
protected |
The generator matrix
of the model.
Definition at line 105 of file MarkovModulatedSubstitutionModel.h.
Referenced by getGenerator(), getScale(), operator=(), operator=(), Qij(), updateMatrices(), updateMatrices(), updateMatrices(), and updateMatrices().
|
protected |
The vector of imaginary parts of the eigen values (zero in case of reversible pmodel).
Definition at line 131 of file MarkovModulatedSubstitutionModel.h.
Referenced by getIEigenValues(), operator=(), operator=(), and updateMatrices().
|
protected |
The
matrix made of left eigen vectors (by row).
Definition at line 115 of file MarkovModulatedSubstitutionModel.h.
Referenced by getd2Pij_dt2(), getdPij_dt(), getPij_t(), getRowLeftEigenVectors(), operator=(), operator=(), and updateMatrices().
|
protected |
Definition at line 81 of file MarkovModulatedSubstitutionModel.h.
Referenced by fireParameterChanged(), getAlphabet(), getModelStates(), getNestedModel(), getRate(), MarkovModulatedSubstitutionModel(), MarkovModulatedSubstitutionModel(), operator=(), operator=(), setFreqFromData(), setNamespace(), setRate(), setScale(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), and ~MarkovModulatedSubstitutionModel().
|
protected |
Definition at line 83 of file MarkovModulatedSubstitutionModel.h.
Referenced by bpp::G2001::G2001(), bpp::G2001::G2001(), bpp::G2001::G2001(), bpp::G2001::G2001(), bpp::G2001::G2001(), bpp::G2001::G2001(), bpp::G2001::G2001(), getModelStates(), getModelStates(), getNumberOfStates(), getPij_t(), operator=(), operator=(), bpp::TS98::TS98(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), bpp::G2001::updateRatesModel(), bpp::G2001::updateRatesModel(), bpp::G2001::updateRatesModel(), and bpp::G2001::updateRatesModel().
|
protected |
Definition at line 82 of file MarkovModulatedSubstitutionModel.h.
Referenced by getModelStates(), getNumberOfStates(), getPij_t(), getRate(), operator=(), operator=(), updateMatrices(), updateMatrices(), updateMatrices(), and updateMatrices().
|
protected |
Definition at line 152 of file MarkovModulatedSubstitutionModel.h.
Referenced by MarkovModulatedSubstitutionModel(), operator=(), operator=(), and setNamespace().
|
protected |
Definition at line 150 of file MarkovModulatedSubstitutionModel.h.
Referenced by operator=(), operator=(), and updateMatrices().
|
mutableprotected |
These ones are for bookkeeping:
Definition at line 141 of file MarkovModulatedSubstitutionModel.h.
Referenced by getPij_t(), getPij_t(), getPij_t(), operator=(), operator=(), and updateMatrices().
|
protected |
Definition at line 91 of file MarkovModulatedSubstitutionModel.h.
Referenced by bpp::G2001::G2001(), operator=(), operator=(), bpp::TS98::TS98(), updateMatrices(), updateMatrices(), updateMatrices(), updateMatrices(), bpp::TS98::updateRatesModel(), and bpp::G2001::updateRatesModel().
|
protected |
Definition at line 92 of file MarkovModulatedSubstitutionModel.h.
Referenced by bpp::G2001::G2001(), operator=(), operator=(), bpp::TS98::TS98(), updateMatrices(), updateMatrices(), bpp::TS98::updateRatesModel(), bpp::TS98::updateRatesModel(), bpp::TS98::updateRatesModel(), bpp::TS98::updateRatesModel(), bpp::G2001::updateRatesModel(), and bpp::G2001::updateRatesModel().
|
protected |
Definition at line 93 of file MarkovModulatedSubstitutionModel.h.
Referenced by bpp::G2001::G2001(), operator=(), operator=(), bpp::TS98::TS98(), updateMatrices(), updateMatrices(), updateMatrices(), bpp::TS98::updateRatesModel(), and bpp::TS98::updateRatesModel().
|
protected |
Definition at line 95 of file MarkovModulatedSubstitutionModel.h.
Referenced by operator=(), operator=(), updateMatrices(), updateMatrices(), and updateMatrices().
|
protected |
The
matrix made of right eigen vectors (by column).
Definition at line 120 of file MarkovModulatedSubstitutionModel.h.
Referenced by getColumnRightEigenVectors(), getd2Pij_dt2(), getdPij_dt(), getPij_t(), operator=(), operator=(), updateMatrices(), updateMatrices(), and updateMatrices().