Samtools is a set of utilities that manipulate nucleotide sequence alignments in the binary BAM format. It imports from and exports to the ascii SAM (Sequence Alignment/Map) and CRAM formats, does sorting, merging and indexing, and allows one to retrieve reads in any regions swiftly. It is designed to work on a stream, and is able to open a BAM or CRAM (not SAM) file on a remote FTP or HTTP server.