Skip to content

Diamond

Diamond is a fast sequence similarity search tool for matching nucleotide or protein sequences against protein databases. It aligns proteins and translated DNA at 100–10,000× the speed of BLAST, supports frameshift alignments for long-read analysis, runs with low resource requirements, and writes a range of output formats (BLAST pairwise, tabular, XML, and taxonomic classification).

License

Free to use and open source under GNU GPLv3.

Available

  • Roihu-CPU: 2.1.10 (module diamond), via the bio-apps module.

Usage

Diamond is part of the bio-apps collection on Roihu. Load the bio-apps module tree and then the Diamond module:

module load bio-apps/v202603
module load diamond/2.1.10

After that, you can check the Diamond help with the command:

diamond help

Reference databases

CSC provides shared Diamond indexes for the NCBI non-redundant (nr) and SwissProt (swiss) protein databases. The diamond module sets the environment variable $DIAMONDDB to their location, and you refer to an index by basename (Diamond appends .dmnd). For example, searching a set of nucleotide sequences against SwissProt:

diamond blastx --query nuc.fasta -d $DIAMONDDB/swiss --out diamond_results.txt -p 4 --max-target-seqs 500

nr is very large, so a search against it (-d $DIAMONDDB/nr) needs substantial memory and time — reserve them accordingly.

Using your own database

You can also search against your own protein sequence database. First build a Diamond index for your reference protein set with diamond makedb:

diamond makedb --in reference_proteins.fasta -d my_ref -p 4

The command above creates a Diamond index file (my_ref.dmnd) that can be used as the query database:

diamond blastx --query nuc.fasta -d my_ref --out diamond_results2.txt -p 4 --max-target-seqs 500

More information

Do you find this page useful?
Thank you for your feedback!
Thank you! Your feedback is appreciated.

Please let us know how we could improve this page by contacting us or by creating an issue in GitHub. You can also edit this page yourself and contribute your improvements by creating a pull request.