BAMINTERVALCOMMENT(1)
π BAMINTERVALCOMMENT(1) π
okay bestie, this page comes from the General Commands Manual section and it's literally about tagging your alignments with interval names. let's get into it π«Ά
πΈ NAME πΈ
bamintervalcomment β sort BAM files by coordinate or query name
not me noticing the NAME section says "sort" while the actual page is about commenting intervals... anyway, that's what the page says, so that's what we're saying π
β¨ SYNOPSIS β¨
bamintervalcomment [options]
π¦ DESCRIPTION π¦
so here's the vibe: bamintervalcomment reads a BAM, SAM or CRAM file plus a file containing a list of named intervals, and then it marks every line in the input with the list of all matching intervals, and stores the resulting file in BAM, SAM or CRAM format. iconic behaviour honestly.
the intervals file needs to be given using the intervals key. the file can be either plain or compressed using gzip. the intervals file is expected to contain one interval per line. each line is assumed to contain a tab separated list of values, where the following columns are used by the program:
- first and second column β contain a pair of names which form the id of the interval
- third column β gives the name of the reference sequence containing the interval
- fifth and sixth column β give the interval on the reference sequence designated by the third column as a pair of non negative integers. both borders are included. (yes, both. inclusive. no cap π )
for each alignment the matching interval designators are stored in the CO (comment) auxiliary field in the form of a semicolon separated list, where each list element is a pair (A,B) given the two id columns of the respective interval. an example of an interval file can be found at http://hgdownload.cse.ucsc.edu/goldenPath/hg19/database/refFlat.txt.gz.
π the key=value pairs π
the following key=value pairs can be given when running the program:
level=<-1|0|1|9|11>β set compression level of the output BAM file. valid values are:-1: zlib/gzip default compression level0: uncompressed1: zlib/gzip level 1 (fast) compression9: zlib/gzip level 9 (best) compression
if libmaus has been compiled with support for igzip (see https://software.intel.com/en-us/articles/igzip-a-high-performance-deflate-compressor-with-optimizations-for-genomic-data) then an additional valid value is:
11: igzip compression
verbose=<1>β valid values are:1: print progress report on standard error0: do not print progress report
tmpfile=<filename>β set the prefix for temporary file namesdisablevalidation=<0|1>β sets whether input validation is performed. valid values are:0: validation is enabled (default)1: validation is disabled
md5=<0|1>β md5 checksum creation for output file. this option can only be given ifoutputformat=bam. then valid values are:0: do not compute checksum. this is the default.1: compute checksum. if themd5filenamekey is set, then the checksum is written to the given file. ifmd5filenameis unset, then no checksum will be computed.
md5filenameβ file name for md5 checksum ifmd5=1.index=<0|1>β compute BAM index for output file. this option can only be given ifoutputformat=bam. then valid values are:0: do not compute BAM index. this is the default.1: compute BAM index. if theindexfilenamekey is set, then the BAM index is written to the given file. ifindexfilenameis unset, then no BAM index will be computed.
indexfilenameβ file name for output BAM index ifindex=1.inputformat=<bam>β input file format. all versions ofbamintervalcommentcome with support for the BAM input format. if the program in addition is linked to the io_lib package, then the following options are valid:bam: BAM (seehttp://samtools.sourceforge.net/SAM1.pdf)sam: SAM (seehttp://samtools.sourceforge.net/SAM1.pdf)cram: CRAM (seehttp://www.ebi.ac.uk/ena/about/cram_toolkit)
outputformat=<bam>β output file format. all versions ofbamintervalcommentcome with support for the BAM output format. if the program in addition is linked to the io_lib package, then the following options are valid:bam: BAM (seehttp://samtools.sourceforge.net/SAM1.pdf)sam: SAM (seehttp://samtools.sourceforge.net/SAM1.pdf)cram: CRAM (seehttp://www.ebi.ac.uk/ena/about/cram_toolkit). this format is not advisable for data sorted by query name. π©
I=<[stdin]>β input filename, standard input if unset.O=<[stdout]>β output filename, standard output if unset.inputthreads=<[1]>β input helper threads, only valid forinputformat=bam.outputthreads=<[1]>β output helper threads, only valid foroutputformat=bam.reference=<[]>β reference FastA file forinputformat=cramandoutputformat=cram. an index file (.fai) is required.range=<>β input range to be processed. this option is only valid if the input is a coordinate sorted and indexed BAM fileintervals=<>β file name of intervals file
π AUTHOR π
Written by German Tischler.
π REPORTING BUGS π
Report bugs to <germant@miltenyibiotec.de>
π COPYRIGHT π
Copyright Β© 2009-2014 German Tischler, Β© 2011-2014 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.
okay that's the whole thing, bestie!! this one's from BIOBAMBAM, dated June 2014 π go tag some intervals, you absolute icon β¨π π
π¦ where this page comes from
- debian bookworm: biobambam2 2.0.185+ds-1 Β· GPL-3.0-or-later
- debian trixie: biobambam2 2.0.185+ds-2 Β· GPL-3.0-or-later
- ubuntu jammy: biobambam2 2.0.183+ds-1 Β· GPL-3.0-or-later
- ubuntu noble: biobambam2 2.0.185+ds-1 Β· GPL-3.0-or-later
- ubuntu questing: biobambam2 2.0.185+ds-2
- ubuntu resolute: biobambam2 2.0.185+ds-2build1 Β· GPL-3.0-or-later
- ubuntu stonking: biobambam2 2.0.185+ds-2build1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms