BAMRECALCULATECIGAR(1)

πŸ‘‘ BAMRECALCULATECIGAR πŸ‘‘

okay bestie, so the manual name is bamrecalculatecigar β€” it lives in the General Commands Manual section, and it's about to fix up your CIGAR strings for you. let's go πŸ’…


✨ NAME ✨

bamrecalculatecigar β€” concatenate BAM files

(yes, that's literally what it says up there in the original, and I am not the one who wrote it, so we keep it fr fr πŸ™ˆ)


πŸŽ€ SYNOPSIS πŸŽ€

bamrecalculatecigar [options]

🌸 DESCRIPTION 🌸

So here's the vibe: bamrecalculatecigar reads a SAM/BAM/CRAM file, and for every aligned read it rewrites the CIGAR string, swapping out the M operations for = and X operations. Then it writes all of that out to a SAM/BAM/CRAM file. ✨

Reads that aren't aligned? They get left alone. Not touched. Not changed. They're minding their own business, we're minding ours. 🫢

Rewriting the CIGAR strings requires a reference in FastA format, no cap. You gotta hand over the path to that FastA file using the reference key. And heads up: your alignment input file needs to be sorted by coordinate. πŸ“

The following key=value pairs can be given:

  • level=<-1|0|1|9|11> β€” set the compression level of the output BAM file. the valid values are:
    • -1 β€” zlib/gzip default compression level
    • 0 β€” uncompressed
    • 1 β€” zlib/gzip level 1 (fast) compression
    • 9 β€” zlib/gzip level 9 (best) compression

And 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 there's one more valid value, and it's:

  • 11 β€” igzip compression
  • verbose=<1> β€” the valid values are:
    • 1 β€” print progress report on standard error
    • 0 β€” do not print progress report
  • tmpfile=<filename> β€” prefix for temporary files. by default the temporary files are created in the current directory πŸ—‚οΈ
  • md5=<0|1> β€” md5 checksum creation for the output file. valid values are:
    • 0 β€” do not compute checksum. This is the default.
    • 1 β€” compute checksum. if the md5filename key is set, then the checksum is written to the given file. if md5filename is unset, then no checksum will be computed.
  • md5filename β€” file name for md5 checksum if md5=1.
  • index=<0|1> β€” compute BAM index for output file. valid values are:
    • 0 β€” do not compute BAM index. This is the default.
    • 1 β€” compute BAM index. if the indexfilename key is set, then the BAM index is written to the given file. if indexfilename is unset, then no BAM index will be computed.
  • indexfilename β€” file name for BAM index if index=1.
  • inputformat=<bam> β€” input file format. all versions of bamsort come 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:
  • outputformat=<bam> β€” output file format. all versions of bamsort come 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:
  • I=<[stdin]> β€” input filename, standard input if unset.
  • O=<[stdout]> β€” output filename, standard output if unset.
  • inputthreads=<[1]> β€” input helper threads, only valid for inputformat=bam.
  • outputthreads=<[1]> β€” output helper threads, only valid for outputformat=bam.
  • reference=<[]> β€” reference FastA file for inputformat=cram and outputformat=cram. an index file (.fai) is required. πŸ“Ž

πŸ’– AUTHOR πŸ’–

Written by German Tischler.


😭 REPORTING BUGS 😭

Report bugs to <germant@miltenyibiotec.de>


Copyright Β© 2009-2016 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.


okay that's the whole thing bestie, and lemme just say β€” this page came from BIOBAMBAM, dated February 2016, and honestly? iconic. periodt πŸ’…βœ¨πŸŽ€