BAMALIGNFRAC(1)

NAME
bamalignfrac - compute fraction of aligned bases in alignment file

SYNOPSIS

bamalignfrac [options] <input.bam>

DESCRIPTION
bamalignfrac reads a SAM/BAM/CRAM file, computes a set of statistical values and outputs these on the standard output channel. The values produced are

*   the number of names passing a given regex filter

*   the number of primary alignments

*   the number of total alignments

*   the total number of bases

*   the total number of aligned bases

*   the fraction of aligned bases

*   the total number of clipped/unaligned bases

*   the number of unmapped reads

These values are printed on the standard output channel at the end of the program run in the last line printed by the program. The program prints a set of line description line prior to that.

The input file needs to be provied in query name sorted order, which can be obtained via e.g.

            $ bamsort SO=queryname

right before being passed to bamalignfrac.

The following key=value pairs can be given:

verbose=<0|1>: print preliminary values for file prefixes while processing the input file

name=<>: only consider reads matching the given regular expression. By default all reads are considered.

AUTHOR
Written by German Tischler-Höhle.

REPORTING BUGS
Report bugs to <germant@miltenyibiotec.de>

COPYRIGHT
Copyright © 2009-2019 German Tischler, © 2011-2013 Genome Research Limited. License GPLv3+: GNU GPL version 3 <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.