Skip to content

cfe-lab/cfetree

Repository files navigation

Lint Typecheck types - Mypy Ruff

CFE Tree Maker

CFE Tree Maker is a Python script that allows you to create and visualize phylogenetic trees in a simple and automated way.

Features

  • Produces phylogenetic trees in PDF format.
  • Customizable label colors and styles.
  • Supports Python 3.10 and higher.

Installation

uv tool install cfetree

Usage

Note: CFE Tree Maker requires trees be generated from Clustal!

To use CFE Tree Maker, run the following command:

cfetree input.newick output.pdf

Alternatively, import it into your own project:

from cfetree import load_tree, export_tree

t = load_tree("A,B,C;")
export_tree(t, "/tmp/tree.pdf", "My tree")

This will generate a PDF file containing the phylogenetic tree.

Contributing

Contributions to CFE Tree Maker are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.

Development

Use uv to manage the environment.

Install all dev dependencies:

uv sync --extra test --extra dev

Test:

uv run pytest

Lint:

uv run ruff check

Format:

uv run ruff format

Type-check:

uv run mypy cfetree tests

License

CFE Tree Maker is licensed under the GNU General Public License v3.0. See the LICENSE file for more details.

About

Simple script for drawing phylogenetic trees

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors