bpp-phyl3 3.0.0
CodonDistanceFrequenciesSubstitutionModel.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: The Bio++ Development Group
2//
3// SPDX-License-Identifier: CECILL-2.1
4
5#ifndef BPP_PHYL_MODEL_CODON_CODONDISTANCEFREQUENCIESSUBSTITUTIONMODEL_H
6#define BPP_PHYL_MODEL_CODON_CODONDISTANCEFREQUENCIESSUBSTITUTIONMODEL_H
7
8
12
13namespace bpp
14{
57{
58public:
74 std::shared_ptr<const GeneticCode> gCode,
75 std::unique_ptr<NucleotideSubstitutionModelInterface> pmod,
76 std::unique_ptr<CodonFrequencySetInterface> pfreq,
77 std::shared_ptr<const AlphabetIndex2> pdist = nullptr,
78 bool paramSynRate = false);
79
97 std::shared_ptr<const GeneticCode> gCode,
98 std::unique_ptr<NucleotideSubstitutionModelInterface> pmod1,
99 std::unique_ptr<NucleotideSubstitutionModelInterface> pmod2,
100 std::unique_ptr<NucleotideSubstitutionModelInterface> pmod3,
101 std::unique_ptr<CodonFrequencySetInterface> pfreq,
102 std::shared_ptr<const AlphabetIndex2> pdist = nullptr,
103 bool paramSynRate = false);
104
106
108 {
110 }
111
112public:
113 void fireParameterChanged(const ParameterList& parameterlist) override;
114
115 std::string getName() const override;
116
117 double getCodonsMulRate(size_t i, size_t j) const override;
118
119 void setNamespace(const std::string&) override;
120
121 void setFreq(std::map<int, double>& frequencies) override;
122
124 {
126 }
127
128 const FrequencySetInterface& frequencySet() const override
129 {
131 }
132
133 bool hasCodonFrequencySet() const override
134 {
136 }
137};
138} // end of namespace bpp.
139#endif // BPP_PHYL_MODEL_CODON_CODONDISTANCEFREQUENCIESSUBSTITUTIONMODEL_H
Abstract class for modelling of non-synonymous and synonymous substitution rates in codon models.
Abstract Class for substitution models on codons parametrized by frequencies.
const CodonFrequencySetInterface & codonFrequencySet() const override
Abstract class for substitution models on codons.
Class for asynonymous substitution models on codons with parameterized equilibrium frequencies and nu...
void fireParameterChanged(const ParameterList &parameterlist) override
void setFreq(std::map< int, double > &frequencies) override
double getCodonsMulRate(size_t i, size_t j) const override
Returns the multiplicative rate specific to two codons specified by their number. The respective gene...
const CodonFrequencySetInterface & codonFrequencySet() const override
CodonDistanceFrequenciesSubstitutionModel * clone() const override
std::string getName() const override
Get the name of the model.
CodonDistanceFrequenciesSubstitutionModel(std::shared_ptr< const GeneticCode > gCode, std::unique_ptr< NucleotideSubstitutionModelInterface > pmod, std::unique_ptr< CodonFrequencySetInterface > pfreq, std::shared_ptr< const AlphabetIndex2 > pdist=nullptr, bool paramSynRate=false)
Build a new CodonDistanceFrequenciesSubstitutionModel object from three pointers to AbstractSubstitut...
Parametrize a set of state frequencies for codons.
Parametrize a set of state frequencies.
Definition: FrequencySet.h:29
Defines the basic types of data flow nodes.