Treetime

Latest version: v2024.4

Safety actively analyzes 706267 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 4

0.9.6

* in cases when very large polytomies are resolved, the multiplication of the discretized message results in messages/distributions of length 1. This resulted in an error, since interpolation objects require at least two points. This is now caught and a small discrete grid created.
* increase recursion limit to 10000 by default. The recursion limit can now also be set via the environment variable `TREETIME_RECURSION_LIMIT`.
* removed unused imports, fixed typos
* add new way to resolve polytomies. the previous polytomy resolution greedily pulled out pairs of child-clades at a time and merged then into a single clade. This often results in atypical caterpillar like subtrees. This is undesirable since it (i) is very atypical, (ii) causes numerical issues due to repeated convolutions, and (iii) triggers recursion errors during newick export. The new optional way of resolving replaces a multi-furcation by a randomly generated coalescent tree that backwards in time mutates (all mutations are singletons and need to 'go' before coalescence), and merges lineages. Lineages that remain when time reaches the time of the parent remain as children of the parent. This new way of resolving is much faster for large polytomies. This experimental feature can be used via the flag `--stochastic-resolve`. Note that the outcome of this stochastic resolution is stochastic!

0.9.5

* fix bug that omitted the inferred state of the root in the nexus export of the migration command
* add CLI flag and functionality to load sequence evolution models inferred and saved by TreeTime as human-readable text files. The flag is `--custom-gtr <filename>` and overwrites any arguments passed under the `--gtr` flag.
* explicitly specify the optimization method, brackets, bounds, and tolerances in calls of `scipy.optimize.minimize` to suppress scipy warning. Scipy had previously silently ignored bounds when the method wasn't explicitly set to `bounded`.

0.9.4

* avoid negative variance associated with branch lengths in tree regression. This could happen in rare cases when marginal time tree estimation returned short negative branch length and the variance was estimated as being proportional to branch length. Variances in the `TreeRegression` clock model are now always non-negative.
* downsample the grid during multiplication of distribution objects. This turned out to be an issue for trees with very large polytomies. In these cases, a large number of distributions get multiplied which resulted in grid sizes above 100000 points. Grid sizes are now downsampled to the average grid size.

0.9.3

* Add extra error class for "unknown" (==unhandled) errors
* Wrap `run` function and have it optionally raise unhandled exceptions as `TreeTimeUnknownError`.
This is mainly done to improve interaction with `augur` that uses `TreeTime` internals as a library.
(both by anna-parker with input from victorlin)

[PR 206](https://github.com/neherlab/treetime/pull/206)
[PR 208](https://github.com/neherlab/treetime/pull/208)

0.9.2

bug fix release:
* CLI now works for windows (thanks corneliusroemer for the fix)
* fixes vcf parsing. haploid no-calls were not properly parsed and treated as reference (thanks jodyphelan for the issue).
* fix file names in CLI output. (thanks gtonkinhill)

0.9.1

This release is mostly a bug-fix release and contains some additional safeguards against unwanted side-effects of greedy polytomy resolution.

* resolve polytomies only when significant LH gain can be achieved
* performance enhancement in pre-order iteration during marginal time tree estimate when hitting large polytomies.
* allow users to set branch specific rates (only when used as a library)

Page 2 of 4

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.