Using a codon model¶
We load the unaligned sequences we will use in our examples.
Codon alignment with default settings¶
The default settings will result in estimation of a guide tree (using percent identity between the sequences). The default “codon” model is MG94HKY.
The parameters used to construct the alignment, including the guide tree and substitution model, are record in the info
attribute.
Note
If can also specify unique_guides=True
, which means a guide tree will be estimated for every alignment.
Specify a different distance measure for estimating the guide tree¶
The distance measures available are the same as for the nucleotide case (percent, TN93 or paralinear).
Note
An estimated guide tree has its branch lengths scaled so they are consistent with usage in a codon model.
Providing a guide tree¶
Note
The guide tree needs to have branch lengths, otherwise a ValueError
is raised.
Specifying the gap parameters¶
Specifying the substitution model and parameters¶
Any codon substitution model can be used. (See cogent3.available_models()
.) If you provide parameter values, those must be consistent with the model definition.