etetoolkit

Phylogenetic tree toolkit (ETE). Tree manipulation (Newick/NHX), evolutionary event detection, orthology/paralogy, NCBI taxonomy, visualization (PDF/SVG), for phylogenomics.

Category

Other Tools

Install

Hot:8

Download and extract to your skills directory

Copy command and send to OpenClaw for auto-install:

Download and install this skill https://openskills.cc/api/download?slug=k-dense-ai-scientific-skills-etetoolkit&locale=en&source=copy

ETE Toolkit - Phylogenetic Tree Analysis and Evolutionary Research Tool

Features Overview

ETE Toolkit is a Python toolkit for analysis of phylogenetic and hierarchical tree structures, supporting tree operations, detection of evolutionary events, identification of orthologous genes, NCBI taxonomy integration, and publication-quality visualization, suitable for comparative genomics and evolutionary biology research.

Use Cases

1. Comparative Genomics Research

Complete workflow from gene trees to ortholog identification: load gene trees and sequence alignments, configure species naming rules, automatically detect gene duplication and speciation events, annotate lineage information using the NCBI taxonomy database, and ultimately extract orthologous groups and visualize them.

2. Phylogenetic Tree Visualization and Figures for Publications

Generate publication-quality phylogenies: supports rectangular and circular layouts, customizable node colors, shapes and sizes, addition of annotations like text, charts and heatmaps, and export to high-resolution PNG, PDF and SVG vector formats to meet journal submission requirements.

3. Batch Processing and Comparison of Tree Data

Bulk preprocessing operations such as format conversion, re-rooting, and branch pruning; quantify topological differences between trees using the Robinson-Foulds distance, identify unique and shared splits, construct multi-tree distance matrices — suitable for comparing and evaluating phylogenetic inference methods.

Core Features

1. Tree Manipulation and Topology Analysis

Read and export multiple formats including Newick, NHX, PhyloXML and NeXML, supporting preorder, postorder and level-order traversal strategies. Provide topology modification functions such as branch pruning, re-rooting, node collapse and multifurcation resolution, compute branch lengths and topology distances, and compare trees using the Robinson-Foulds distance.

2. Evolutionary Event and Homology Detection

Associate gene trees with multiple sequence alignments, automatically or custom-extract species names. Detect gene duplication and speciation events using species-overlap or tree reconciliation algorithms, thereby identifying orthologs and paralogs; support splitting trees by duplication events and collapsing lineage-specific expansions.

3. NCBI Taxonomy Integration

Automatically download and locally cache the NCBI taxonomy database (approximately 300MB), enabling bidirectional conversion between taxonomic IDs and scientific names. Retrieve full lineage information, build a minimal connecting tree for a specified list of species, and automatically add taxonomy annotations to phylogenetic tree nodes.

Frequently Asked Questions

Which phylogenetic tree formats does ETE Toolkit support?

ETE supports multiple variants of the Newick format (formats 0–100), including the default format with branch lengths, formats with internal node names, formats with support values, and the NHX (New Hampshire eXtended) extension. It also supports reading and writing PhyloXML and NeXML formats.

How to detect duplication and speciation events in gene trees?

Load the gene tree using the PhyloTree class and configure a species naming function, then call the get_descendant_evol_events() method to automatically detect evolutionary events. When traversing tree nodes, you can use the evoltype attribute to distinguish duplication (D) and speciation (S) events, and thereby identify orthologs and paralogs of a query gene.

How does ETE3 visualize phylogenetic trees and export PDFs?

Configure TreeStyle to set display options and scaling, use NodeStyle to customize node color and size, and implement dynamic styling based on node attributes via a layout_fn function. Call tree.render() to export to PDF, SVG or PNG formats, with support for custom resolution and size units.