bpp-phyl3
3.0.0
|
Sequence evolution framework based on a mixture of substitution processes. More...
#include <Bpp/Phyl/Likelihood/PartitionSequenceEvolution.h>
Public Member Functions | |
PartitionSequenceEvolution (std::shared_ptr< SubstitutionProcessCollection > processColl, std::vector< size_t > &posProc) | |
PartitionSequenceEvolution (const PartitionSequenceEvolution &mlc) | |
PartitionSequenceEvolution & | operator= (const PartitionSequenceEvolution &mlc) |
virtual | ~PartitionSequenceEvolution () |
PartitionSequenceEvolution * | clone () const |
size_t | getNumberOfSites () const |
const std::vector< size_t > & | getProcessNumbersPerSite () const |
size_t | getSubstitutionProcessNumber (size_t i) const |
std::map< size_t, std::vector< size_t > > & | mapOfProcessSites () |
const std::map< size_t, std::vector< size_t > > & | mapOfProcessSites () const |
const SubstitutionProcessCollection & | collection () const |
The collection. More... | |
SubstitutionProcessCollection & | collection () |
std::shared_ptr< const SubstitutionProcessCollection > | getCollection () const |
std::shared_ptr< SubstitutionProcessCollection > | getCollection () |
size_t | getNumberOfSubstitutionProcess () const |
Return the number of process used for computation. More... | |
const SubstitutionProcessInterface & | substitutionProcess (size_t number) const |
Return the SubstitutionProcess of a given index position (in nProc_ vector). More... | |
std::shared_ptr< const SubstitutionProcessInterface > | getSubstitutionProcess (size_t number) const |
const std::vector< size_t > & | getSubstitutionProcessNumbers () const |
ParameterList | getSubstitutionProcessParameters (bool independent) const |
Get the parameters associated to substitution processes(s). More... | |
ParameterList | getSubstitutionModelParameters (bool independent) const |
Get the parameters associated to substitution model(s). More... | |
ParameterList | getRateDistributionParameters (bool independent) const |
Get the parameters associated to the rate distribution(s). More... | |
ParameterList | getRootFrequenciesParameters (bool independent) const |
Get the parameters associated to the root frequencies(s). More... | |
ParameterList | getBranchLengthParameters (bool independent) const |
Get the branch lengths parameters. More... | |
virtual ParameterList | getNonDerivableParameters () const |
All non derivable parameters. More... | |
virtual void | fireParameterChanged (const ParameterList ¶meters) |
void | setParameters (const ParameterList ¶meters) |
virtual bool | isCompatibleWith (const AlignmentDataInterface &data) const |
test if data fits this model More... | |
const StateMapInterface & | stateMap () const |
std::shared_ptr< const StateMapInterface > | getStateMap () const |
virtual size_t | getNumberOfIndependentParameters () const=0 |
size_t | getNumberOfIndependentParameters () const |
virtual void | aliasParameters (const std::string &p1, const std::string &p2)=0 |
virtual void | aliasParameters (std::map< std::string, std::string > &unparsedParams, bool verbose)=0 |
void | aliasParameters (const std::string &p1, const std::string &p2) |
void | aliasParameters (std::map< std::string, std::string > &unparsedParams, bool verbose) |
virtual void | unaliasParameters (const std::string &p1, const std::string &p2)=0 |
void | unaliasParameters (const std::string &p1, const std::string &p2) |
virtual const ParameterList & | getIndependentParameters () const=0 |
const ParameterList & | getIndependentParameters () const |
virtual std::vector< std::string > | getAlias (const std::string &name) const=0 |
virtual std::vector< std::string > | getAlias (const std::string &name) const |
virtual std::map< std::string, std::string > | getAliases () const=0 |
virtual std::map< std::string, std::string > | getAliases () const |
virtual bool | hasParameter (const std::string &name) const=0 |
bool | hasParameter (const std::string &name) const override |
virtual const ParameterList & | getParameters () const=0 |
const ParameterList & | getParameters () const override |
virtual const Parameter & | parameter (const std::string &name) const=0 |
const Parameter & | parameter (const std::string &name) const override |
virtual double | getParameterValue (const std::string &name) const=0 |
double | getParameterValue (const std::string &name) const override |
virtual void | setAllParametersValues (const ParameterList ¶meters)=0 |
void | setAllParametersValues (const ParameterList ¶meters) override |
virtual void | setParameterValue (const std::string &name, double value)=0 |
void | setParameterValue (const std::string &name, double value) override |
virtual void | setParametersValues (const ParameterList ¶meters)=0 |
void | setParametersValues (const ParameterList ¶meters) override |
virtual bool | matchParametersValues (const ParameterList ¶meters)=0 |
bool | matchParametersValues (const ParameterList ¶meters) override |
virtual void | removeConstraint (const std::string &name)=0 |
void | removeConstraint (const std::string &name) override |
virtual void | setConstraint (const std::string &name, std::shared_ptr< ConstraintInterface > constraint)=0 |
void | setConstraint (const std::string &name, std::shared_ptr< ConstraintInterface > constraint) override |
virtual size_t | getNumberOfParameters () const=0 |
size_t | getNumberOfParameters () const override |
virtual void | setNamespace (const std::string &prefix)=0 |
void | setNamespace (const std::string &prefix) |
virtual std::string | getNamespace () const=0 |
std::string | getNamespace () const override |
virtual std::string | getParameterNameWithoutNamespace (const std::string &name) const=0 |
std::string | getParameterNameWithoutNamespace (const std::string &name) const override |
bool | hasIndependentParameter (const std::string &name) const |
ParameterList | getAliasedParameters (const ParameterList &pl) const |
ParameterList | getFromParameters (const ParameterList &pl) const |
std::string | getFrom (const std::string &name) const |
const std::shared_ptr< Parameter > & | getParameter (const std::string &name) const |
Protected Member Functions | |
virtual ParameterList & | getParameters_ ()=0 |
ParameterList & | getParameters_ () override |
const std::shared_ptr< Parameter > & | getParameter (size_t i) const |
std::shared_ptr< Parameter > & | getParameter (size_t i) |
void | addParameter_ (Parameter *parameter) |
void | addParameters_ (const ParameterList ¶meters) |
void | shareParameter_ (const std::shared_ptr< Parameter > ¶meter) |
void | shareParameters_ (const ParameterList ¶meters) |
void | includeParameters_ (const ParameterList ¶meters) |
void | deleteParameter_ (size_t index) |
void | deleteParameter_ (std::string &name) |
void | deleteParameters_ (const std::vector< std::string > &names) |
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 |
Protected Attributes | |
std::shared_ptr< SubstitutionProcessCollection > | processColl_ |
std::vector< size_t > | nProc_ |
the vector of the substitution process numbers, as they are used in this order. More... | |
Private Attributes | |
std::vector< size_t > | vProc_ |
vector of the substitution process numbers along the sequence. More... | |
size_t | vSize_ |
std::map< size_t, std::vector< size_t > > | mProcPos_ |
On the reverse, for each process number, the vector of the sites where it is used. More... | |
ParameterList | independentParameters_ |
std::map< std::string, std::shared_ptr< AliasParameterListener > > | aliasListenersRegister_ |
ParameterList | parameters_ |
std::string | prefix_ |
Sequence evolution framework based on a mixture of substitution processes.
Definition at line 20 of file PartitionSequenceEvolution.h.
PartitionSequenceEvolution::PartitionSequenceEvolution | ( | std::shared_ptr< SubstitutionProcessCollection > | processColl, |
std::vector< size_t > & | posProc | ||
) |
Definition at line 14 of file PartitionSequenceEvolution.cpp.
References mProcPos_, bpp::MultiProcessSequenceEvolution::nProc_, bpp::MultiProcessSequenceEvolution::processColl_, vProc_, and vSize_.
Referenced by clone().
|
inline |
Definition at line 51 of file PartitionSequenceEvolution.h.
|
inlinevirtual |
Definition at line 68 of file PartitionSequenceEvolution.h.
|
inlinevirtual |
Implements bpp::AbstractParameterAliasable.
Definition at line 70 of file PartitionSequenceEvolution.h.
References PartitionSequenceEvolution().
|
inlineinherited |
Definition at line 69 of file MultiProcessSequenceEvolution.h.
|
inlineinherited |
The collection.
Definition at line 65 of file MultiProcessSequenceEvolution.h.
|
virtualinherited |
Reimplemented from bpp::AbstractParameterAliasable.
Reimplemented in bpp::MixtureSequenceEvolution, bpp::HmmSequenceEvolution, and bpp::AutoCorrelationSequenceEvolution.
Definition at line 30 of file MultiProcessSequenceEvolution.cpp.
References bpp::MultiProcessSequenceEvolution::processColl_.
Referenced by bpp::AutoCorrelationSequenceEvolution::fireParameterChanged(), bpp::HmmSequenceEvolution::fireParameterChanged(), and bpp::MixtureSequenceEvolution::fireParameterChanged().
|
virtualinherited |
Get the branch lengths parameters.
Implements bpp::SequenceEvolution.
Definition at line 85 of file MultiProcessSequenceEvolution.cpp.
References bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
inlineinherited |
Definition at line 71 of file MultiProcessSequenceEvolution.h.
|
inlineinherited |
Definition at line 67 of file MultiProcessSequenceEvolution.h.
|
virtualinherited |
All non derivable parameters.
Usually, this contains all substitution model parameters and rate distribution, and alias.
Implements bpp::SequenceEvolution.
Reimplemented in bpp::MixtureSequenceEvolution, and bpp::AutoCorrelationSequenceEvolution.
Definition at line 97 of file MultiProcessSequenceEvolution.cpp.
References bpp::AbstractParameterAliasable::getAliasedParameters(), bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
Referenced by bpp::AutoCorrelationSequenceEvolution::getNonDerivableParameters(), and bpp::MixtureSequenceEvolution::getNonDerivableParameters().
|
inline |
Definition at line 73 of file PartitionSequenceEvolution.h.
References vSize_.
Referenced by bpp::EvolutionSequenceSimulator::resetSiteSimulators().
|
inlineinherited |
Return the number of process used for computation.
Definition at line 76 of file MultiProcessSequenceEvolution.h.
Referenced by bpp::PhylogeneticsApplicationTools::printParameters().
|
inline |
Definition at line 78 of file PartitionSequenceEvolution.h.
References vProc_.
|
virtualinherited |
Get the parameters associated to the rate distribution(s).
Implements bpp::SequenceEvolution.
Definition at line 61 of file MultiProcessSequenceEvolution.cpp.
References bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
virtualinherited |
Get the parameters associated to the root frequencies(s).
Implements bpp::SequenceEvolution.
Definition at line 73 of file MultiProcessSequenceEvolution.cpp.
References bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
inlineinherited |
Definition at line 53 of file SequenceEvolution.h.
References bpp::SubstitutionProcessInterface::getStateMap(), bpp::SequenceEvolution::getSubstitutionProcessNumbers(), and bpp::SequenceEvolution::substitutionProcess().
|
virtualinherited |
Get the parameters associated to substitution model(s).
Implements bpp::SequenceEvolution.
Definition at line 49 of file MultiProcessSequenceEvolution.cpp.
References bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
inlinevirtualinherited |
Implements bpp::SequenceEvolution.
Definition at line 87 of file MultiProcessSequenceEvolution.h.
|
inline |
Definition at line 88 of file PartitionSequenceEvolution.h.
References vProc_, and vSize_.
Referenced by bpp::EvolutionSequenceSimulator::resetSiteSimulators().
|
inlinevirtualinherited |
Implements bpp::SequenceEvolution.
Definition at line 92 of file MultiProcessSequenceEvolution.h.
Referenced by bpp::PhylogeneticsApplicationTools::printParameters().
|
virtualinherited |
Get the parameters associated to substitution processes(s).
Implements bpp::SequenceEvolution.
Definition at line 37 of file MultiProcessSequenceEvolution.cpp.
References bpp::ParameterList::includeParameters(), bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
virtualinherited |
test if data fits this model
Implements bpp::SequenceEvolution.
Definition at line 122 of file MultiProcessSequenceEvolution.cpp.
References bpp::MultiProcessSequenceEvolution::nProc_, and bpp::MultiProcessSequenceEvolution::processColl_.
|
inline |
Definition at line 95 of file PartitionSequenceEvolution.h.
References mProcPos_.
Referenced by bpp::PhylogeneticsApplicationTools::printAnalysisInformation(), and bpp::PhylogeneticsApplicationTools::printParameters().
|
inline |
Definition at line 100 of file PartitionSequenceEvolution.h.
References mProcPos_.
|
inline |
Definition at line 57 of file PartitionSequenceEvolution.h.
References mProcPos_, bpp::MultiProcessSequenceEvolution::operator=(), vProc_, and vSize_.
|
inherited |
Definition at line 114 of file MultiProcessSequenceEvolution.cpp.
References bpp::AbstractParameterAliasable::setParametersValues().
|
inlineinherited |
Definition at line 48 of file SequenceEvolution.h.
References bpp::SequenceEvolution::getSubstitutionProcessNumbers(), bpp::SubstitutionProcessInterface::stateMap(), and bpp::SequenceEvolution::substitutionProcess().
|
inlinevirtualinherited |
Return the SubstitutionProcess of a given index position (in nProc_ vector).
Implements bpp::SequenceEvolution.
Definition at line 82 of file MultiProcessSequenceEvolution.h.
|
private |
On the reverse, for each process number, the vector of the sites where it is used.
Convenient for process specific site patterns.
Definition at line 38 of file PartitionSequenceEvolution.h.
Referenced by mapOfProcessSites(), operator=(), and PartitionSequenceEvolution().
|
protectedinherited |
the vector of the substitution process numbers, as they are used in this order.
Definition at line 37 of file MultiProcessSequenceEvolution.h.
Referenced by bpp::MultiProcessSequenceEvolution::getBranchLengthParameters(), bpp::MultiProcessSequenceEvolution::getNonDerivableParameters(), bpp::MultiProcessSequenceEvolution::getRateDistributionParameters(), bpp::MultiProcessSequenceEvolution::getRootFrequenciesParameters(), bpp::MultiProcessSequenceEvolution::getSubstitutionModelParameters(), bpp::MultiProcessSequenceEvolution::getSubstitutionProcessParameters(), bpp::MultiProcessSequenceEvolution::isCompatibleWith(), bpp::MultiProcessSequenceEvolution::MultiProcessSequenceEvolution(), bpp::MultiProcessSequenceEvolution::operator=(), and PartitionSequenceEvolution().
|
protectedinherited |
Definition at line 31 of file MultiProcessSequenceEvolution.h.
Referenced by bpp::AutoCorrelationSequenceEvolution::AutoCorrelationSequenceEvolution(), bpp::MultiProcessSequenceEvolution::fireParameterChanged(), bpp::MultiProcessSequenceEvolution::getBranchLengthParameters(), bpp::MultiProcessSequenceEvolution::getNonDerivableParameters(), bpp::MultiProcessSequenceEvolution::getRateDistributionParameters(), bpp::MultiProcessSequenceEvolution::getRootFrequenciesParameters(), bpp::MultiProcessSequenceEvolution::getSubstitutionModelParameters(), bpp::MultiProcessSequenceEvolution::getSubstitutionProcessParameters(), bpp::HmmSequenceEvolution::HmmSequenceEvolution(), bpp::MultiProcessSequenceEvolution::isCompatibleWith(), bpp::MultiProcessSequenceEvolution::MultiProcessSequenceEvolution(), bpp::MultiProcessSequenceEvolution::operator=(), and PartitionSequenceEvolution().
|
private |
vector of the substitution process numbers along the sequence.
Definition at line 27 of file PartitionSequenceEvolution.h.
Referenced by getProcessNumbersPerSite(), getSubstitutionProcessNumber(), operator=(), and PartitionSequenceEvolution().
|
private |
Definition at line 29 of file PartitionSequenceEvolution.h.
Referenced by getNumberOfSites(), getSubstitutionProcessNumber(), operator=(), and PartitionSequenceEvolution().