Add paragraph about iplotx in Phylo tutorial (#5028)

Add mention in NEWS.rst
This commit is contained in:
Fabio Zanini
2025-10-09 19:27:43 +11:00
committed by GitHub
parent 9111417121
commit e763ca5721
3 changed files with 34 additions and 0 deletions

View File

@ -240,6 +240,35 @@ well as its descendents. The common ancestor of E and F turns out to be
just under the root, and with this coloring we can see exactly where the
root of the tree is.
Drawing trees with iplotx
~~~~~~~~~~~~~~~~~~~~~~~~~
For users seeking advanced styling options, Bio.Phylo trees are natively
supported by the external library ``iplotx``:
https://iplotx.readthedocs.io/en/latest/
``iplotx`` enables customisation of many aspects of the visualisation,
including layout, vertex and branch properties, cascading backgrounds,
and labels. Here is a self-contained example.
.. code:: pycon
>>> from Bio import Phylo
>>> import iplotx as ipx
>>> tree = Phylo.read("simple.dnd", "newick")
>>> ipx.tree(tree, leaf_deep=True, leaf_labels=True, style="tree")
.. figure:: ../images/phylo-color-iplotx.png
:alt: A colorized tree drawn with ``iplotx.tree``.
:name: fig:phylo-color-iplotx
:width: 70.0%
``iplotx`` has an extensive `gallery of examples <https://iplotx.readthedocs.io/en/latest/gallery/index.html>`__.
Writing tree to file
~~~~~~~~~~~~~~~~~~~~
My, weve accomplished a lot! Lets take a break here and save our work.
Call the ``write`` function with a file name or handle — here we use
standard output, to see what would be written — and the format

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

View File

@ -45,12 +45,17 @@ being used for additional metadata, typically from computational tools.
``Bio.PDB.PDBIO`` will now raise module specific warnings: ``Bio.PDB.PDBExceptions.PDBIOWarning``.
The ``iplotx`` library is mentioned in the Tutorial as an option to visualise
trees using complex style options.
Many thanks to the Biopython developers and community for making this release
possible, especially the following contributors:
- Rachel Stern (first contribution)
- Oliver Wissett (first contribution)
- Samuel Prince (first contribution)
- Fabio Zanini
15 January 2025: Biopython 1.85
===============================