taxonkit

module
v0.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 24, 2021 License: MIT

README

TaxonKit - A Cross-platform and Efficient NCBI Taxonomy Toolkit

taxonkit

Table of Contents

Features

Subcommands

Subcommand Function
list List taxonomic subtrees (taxIDs) bellow given taxIDs
lineage Query taxonomic lineage of given taxIDs
reformat Reformat lineage in canonical ranks
name2taxid Convert scientific names to taxIDs
filter Filter taxIDs by taxonomic rank range
lca Compute lowest common ancestor (LCA) for taxIDs
taxid-changelog Create taxID changelog from dump archives
version Print version information and check for update
genautocomplete Generate shell autocompletion script

Benchmark

  1. Getting full lineage for given taxIDs

Dataset

  1. Download and decompress taxdump.tar.gz: ftp://ftp.ncbi.nih.gov/pub/taxonomy/taxdump.tar.gz
  2. Copy names.dmp, nodes.dmp, delnodes.dmp and merged.dmp to data directory: $HOME/.taxonkit, e.g., /home/shenwei/.taxonkit ,
  3. Optionally copy to some other directories, and later you can refer to using flag --data-dir, or environment variable TAXONKIT_DB.

All-in-one command:

wget -c ftp://ftp.ncbi.nih.gov/pub/taxonomy/taxdump.tar.gz 
tar -zxvf taxdump.tar.gz

mkdir -p $HOME/.taxonkit
cp names.dmp nodes.dmp delnodes.dmp merged.dmp $HOME/.taxonkit

Installation

Go to Download Page for more download options and changelogs.

TaxonKit is implemented in Go programming language, executable binary files for most popular operating systems are freely available in release page.

Method 1: Download binaries (latest stable/dev version)

Just download compressed executable file of your operating system, and decompress it with tar -zxvf *.tar.gz command or other tools. And then:

  1. For Linux-like systems

    1. If you have root privilege simply copy it to /usr/local/bin:

       sudo cp taxonkit /usr/local/bin/
      
    2. Or copy to anywhere in the environment variable PATH:

       mkdir -p $HOME/bin/; cp taxonkit $HOME/bin/
      
  2. For Windows, just copy taxonkit.exe to C:\WINDOWS\system32.

Method 2: Install via conda (latest stable version) Install-with-conda Anaconda Cloud downloads
conda install -c bioconda taxonkit
Method 3: Install via homebrew (latest stable version)
brew install brewsci/bio/taxonkit
Method 4: For Go developer (latest stable/dev version)
go get -u github.com/shenwei356/taxonkit/taxonkit

Bash-completion

Note: The current version supports Bash only. This should work for *nix systems with Bash installed.

Howto:

  1. run: taxonkit genautocomplete

  2. create and edit ~/.bash_completion file if you don't have it.

     nano ~/.bash_completion
    

    add the following:

     for bcfile in ~/.bash_completion.d/* ; do
       . $bcfile
     done
    

Citation

If you use TaxonKit in your work, please cite the preprint.

Contact

Create an issue to report bugs, propose new functions or ask for help.

License

MIT License

Starchart

Stargazers over time

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL