5 #include "../FrequencySet/NucleotideFrequencySet.h"
16 unique_ptr<CodonFrequencySetInterface> pfreq,
17 const std::string& prefix) :
27 vector<unique_ptr<FrequencySetInterface>> vFS;
30 for (
unsigned int i = 0; i < 3; ++i)
32 vFS.push_back(make_unique<FixedNucleotideFrequencySet>(pfreq->getCodonAlphabet()->getNucleicAlphabet()));
37 for (
unsigned int i = 0; i < 3; ++i)
39 vFS.push_back(make_unique<FullNucleotideFrequencySet>(pfreq->getCodonAlphabet()->getNucleicAlphabet()));
43 pfreq->getGeneticCode(),
46 posFreqSet_->setFrequencies(pfreq->getFrequencies());
50 posFreqSet_->setNamespace(prefix + pfreq->getNamespace());
70 posFreqSet_->setFrequenciesFromAlphabetStatesFrequencies(frequencies);
81 for (
size_t k = 0; k < 3; k++)
83 if ((i2 % 4) != (j2 % 4))
AbstractCodonPhaseFrequenciesSubstitutionModel(std::unique_ptr< CodonFrequencySetInterface > pfreq, const std::string &prefix)
Build a AbstractCodonPhaseFrequenciesSubstitutionModel instance.
double getCodonsMulRate(size_t, size_t) const override
Returns the multiplicative rate specific to two codons specified by their number. The respective gene...
void setFreq(std::map< int, double > &frequencies) override
std::unique_ptr< CodonFrequencySetInterface > posFreqSet_
Position dependent version of Codon Frequencies Set.
virtual ~AbstractCodonPhaseFrequenciesSubstitutionModel()
void fireParameterChanged(const ParameterList ¶meters) override
void addParameters_(const ParameterList ¶meters)
bool matchParametersValues(const ParameterList ¶meters) override
the Frequencies in codons are the product of Independent Frequencies in letters with the frequencies ...
the Frequencies in codons are the product of the frequencies for a unique FrequencySet in letters,...
FrequencySet useful for homogeneous and stationary models, codon implementation.
virtual const Vdouble & getFrequencies() const =0
Frequencies in words computed from the frequencies on letters. The parameters are the parameters of t...
virtual const FrequencySetInterface & frequencySetForLetter(size_t i) const =0
Returns the n-th FrequencySet.
Defines the basic types of data flow nodes.