heattree_py

Interactive Phylogenetic Tree Visualization

A Python package for interactive phylogenetic and taxonomic tree visualization in Python and Jupyter notebooks using the heat-tree JavaScript library.

Installation

pip install heattree_py

Quick Start

from heattree_py import heat_tree

# Minimal example with a Newick string
heat_tree("(A:0.1,B:0.2,(C:0.3,D:0.4):0.5);")

Features

  • Interactive Visualization - Interactive phylogenetic tree visualization with rectangular and circular layouts
  • Metadata Support - Visualize categorical and continuous variables through color and size
  • Tree Manipulation - Collapse, expand, hide, and reveal subtrees interactively
  • Export Options - Export visualizations to SVG and PNG formats
  • Multiple Tree Formats - Support for Newick, Nexus, and Python tree objects (ete3, dendropy, Biopython, scikit-bio)
  • Self-Contained - Works in static HTML exports (no running kernel required)

License

MIT License. See the GitHub repository for details.

Contributing

Contributions and feedback are welcome! Please visit the GitHub repository to report issues or submit pull requests.