Skip to content

Installing TACT

TACT is a Python-based tool that relies on several key scientific packages, including click, DendroPy, and NumPy, which are automatically installed when you install TACT.

Which installation method should I use?

  • pipx (recommended): Fastest, and works on Windows, Mac, and Linux with Python 3.12 or newer.
  • Docker: Use this if you can't install Python, or want a fixed environment. It is a little slower than pipx.
  • Other methods: Not recommended or supported.

pipx is a tool that installs Python applications in isolated environments.

First, install pipx.

Then run:

pipx install tact

Docker

If you can't install Python, you can run TACT from its Docker image instead.

Install Docker Desktop and run the following to download the TACT image:

docker pull jonchang/tact:latest

Then, run TACT from the container image, giving it access to your current working directory:

mkdir -p examples
cd examples
curl -LO https://raw.githubusercontent.com/jonchang/tact/HEAD/examples/Carangaria.csv
curl -LO https://raw.githubusercontent.com/jonchang/tact/HEAD/examples/Carangaria.tre
docker run -it -v "$(pwd)":/workdir -w /workdir jonchang/tact tact_build_taxonomic_tree Carangaria.csv --output Carangaria.taxonomy.tre
docker run -it -v "$(pwd)":/workdir -w /workdir jonchang/tact tact_add_taxa --backbone Carangaria.tre --taxonomy Carangaria.taxonomy.tre --output Carangaria.tacted

Here's a screencast of how to use the Docker commands:

The above Docker image defaults to the latest tagged release. In the rare case you need to use a different version, a full list of tags is available on Docker Hub.

Verifying your installation

After installing, verify that TACT is working correctly:

tact_add_taxa --version

You should see the version number. If you get a "command not found" error, make sure TACT is in your PATH.

Next steps

Once TACT is installed, check out the Tutorial to learn how to use it, or read the Background to understand what TACT does.