Skip to main content

PyPI License: MIT CI Docs

PhyloZoo logo

PhyloZoo is a Python package for working with phylogenetic networks and related evolutionary data types. PhyloZoo aims to provide the foundational infrastructure for phylogenetic network analysis in Python—a common framework that other packages can build on.


Key Features

  • Directed & semi-directed networks — represent phylogenetic networks as fully directed rooted DAGs or as semi-directed/mixed graphs that allow root uncertainty. Both representations are validated on construction to guarantee well-formed phylogenetic objects. Includes a rich library of operations: network classifications, generators, conversions between representations, and much more.
  • Quartets, triplets, splits & distance matrices — support for quartet and triplet systems, split systems, and pairwise distance matrices: the core building blocks for phylogenetic inference and comparison.
  • Multiple sequence alignments — store and manipulate sequence data with efficient NumPy-backed arrays, including bootstrapping and site-pattern extraction.
  • Flexible visualization — plot networks with different layouts and fine-grained control over styling, labels, and coloring via Matplotlib.
  • Standard file formats — read and write common phylogenetic formats including eNewick, FASTA, NEXUS, and PHYLIP, making it easy to integrate with existing workflows.

Installation

To install the recommended version that includes vizualization, do:

pip install phylozoo[viz]

Quickstart

Build a small rooted network with a hybrid node, inspect it, save it and plot it:

import phylozoo as pz

# A rooted network on four taxa with one hybrid node (edges are parent-child tuples)
network = pz.DirectedPhyNetwork(
    edges=[
        ("root", "u1"), ("root", "u2"),
        ("u1", "A"), ("u1", "x"), ("x", "B"),
        ("x", "h"), ("u2", "h"),        # the two edges into the hybrid node h
        ("u2", "D"), ("h", "C"),
    ],
)

print(network.leaves)                            # {'A', 'B', 'C', 'D'}
print(pz.dnetwork.classifications.level(network))  # 1

# Save network to file (eNewick format)
network.save("my_network.enewick")               # ((A,(B,(C)#H1)),(D,#H1));

# Plot the network
from phylozoo.viz import plot

plot(network, show=True)

See the quickstart tutorial for a longer tour of what PhyloZoo can do.

Documentation

For detailed documentation, installation instructions, tutorials, and API reference, visit the PhyloZoo docs.

Citation

If you use PhyloZoo in your research, please cite:

Niels Holtgrefe. PhyloZoo: a unified framework for phylogenetic network analysis in Python. bioRxiv:10.64898/2026.06.09.731120, 2026.

Metadata

Release files for phylozoo 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for phylozoo 0.3.0
File Size Uploaded
phylozoo-0.3.0.tar.gz 291.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for phylozoo 0.3.0
File Interpreter ABI Platform
phylozoo-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 655.3 kB

Release files / phylozoo-0.3.0.tar.gz

Download URL phylozoo-0.3.0.tar.gz
Size 291.5 kB
Tags Source
SHA-256 checksum
How to use checksums
629bcafac6f1240fa2988067b5ba526b30fc19165e40b3b2d95501cbafb45c26
BLAKE2b-256 checksum
How to use checksums
cbbbe95fb787f9a681832d2c5f77c73dafb135f04e2eb1e56346d16d5107ba6d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.

Transparency log

Release files / phylozoo-0.3.0-py3-none-any.whl

Download URL phylozoo-0.3.0-py3-none-any.whl
Size 363.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
03facaf67c1ab6653f045ee35882de0fe2a04b7ebfc525867b5d118b6fb4987b
BLAKE2b-256 checksum
How to use checksums
f0a5c869db73c8be97a0445102103ed5040d205c08f2481518b09586310deb77
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 12, 2026.

Transparency log

Release history Release notifications | RSS feed

0.4.1

2 release files

0.4.0

2 release files

This release

0.3.0 This release

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page