bamtools command not found

In this troubleshooting guide we learn how to fix bamtools command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

bamtools: command not found

or when using sudo you get the following error message

sudo: bamtools: command not found

Solutions to bamtools: command not found

How To Fix bamtools: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu bamtools is provided by bamtools package.

bamtools is:

BamTools facilitates research analysis and data management using BAM files. It copes with the enormous amount of data produced by current sequencing technologies that is typically stored in compressed, binary formats that are not easily handled by the text-based parsers commonly used in bioinformatics research.

BamTools provides both a C++ API for BAM file support as well as a command-line toolkit.

This is the bamtools command-line toolkit.

Available bamtools commands: convert Converts between BAM and a number of other formats count Prints number of alignments in BAM file(s) coverage Prints coverage statistics from the input BAM file filter Filters BAM file(s) by user-specified criteria header Prints BAM header information index Generates index for BAM file merge Merge multiple BAM files into single file random Select random alignments from existing BAM file(s), intended more as a testing tool. resolve Resolves paired-end reads (marking the IsProperPair flag as needed) revert Removes duplicate marks and restores original base qualities sort Sorts the BAM file according to some criteria split Splits a BAM file on user-specified property, creating a new BAM output file for each value found stats Prints some basic statistics from input BAM file(s)

To fix this problem, we can install more using the command below.

sudo apt-get -y install bamtools

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install bamtools.

sudo apt -y install bamtools

Or if you have aptitude installed you can use the following command.

sudo aptitude install bamtools

Summary

In this tutorial we learn how to fix bamtools command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.