PalantiR scales codon substitution rates to assign
particular meanings to branches on a phylogeny.
There are four scaling schemes implemented:
synonymous is the default scaling. This forces the
branch length to be proportional to the expected number of
synonymous substitutions per site.non-synonymous scaling forces the branch length to be
equivalent to the expected number of non-synonymous
substitutions per site.substitution scaling forces the branch length to be
equivalent to the expected number of both types of
substitutions per site.none can be specified to leave the substitution rates
unscaled.Scaling type is specified as an optional parameter to substitution model constructors, e.g.:
Scaling rate is calculated as:
\[ S(Q, \pi, t) = \sum \sum_{ij}\pi_i Q_{ij}^{(t)} \]
The inner summation is over all the substitutions from each state (codon) \(i\) to each state \(j\). \(Q^{(t)}\) means substitution rate for a substitution of type \(t\) (e.g. synonymous substitution).
At equilibrium the identity is exact: with the default
synonymous scaling, a branch of length one carries one
expected synonymous substitution per codon. On branches where the model
changes and the process is temporarily out of equilibrium, the
branch-length currency is maintained by the rescaling machinery
described in Temporal
Heterogeneity Rescaling.