BUILDCONSENSUS.PY(1)

๐Ÿ’– BUILDCONSENSUS.PY(1) โ€” User Commands ๐Ÿ’–


โœจ NAME โœจ

BuildConsensus.py - Builds a consensus sequence for each set of input sequences ๐Ÿ’…


๐Ÿฆ‹ DESCRIPTION ๐Ÿฆ‹

Okay bestie, so this tool takes your input sequences and builds a consensus sequence for each set of them. Ngl the usage line looks like a whole essay, but it's just the list of everything you're allowed to pass in ๐Ÿซถ

usage: BuildConsensus.py [--version] [-h] -s SEQ_FILES [SEQ_FILES ...]

       [-o OUT_FILES [OUT_FILES ...]] [--outdir OUT_DIR]
              [--outname OUT_NAME] [--log LOG_FILE] [--failed] [--fasta]
              [--delim DELIMITER DELIMITER DELIMITER] [--nproc NPROC] [-n
              MIN_COUNT] [--bf BARCODE_FIELD] [-q MIN_QUAL] [--freq MIN_FREQ]
              [--maxgap MAX_GAP] [--pf PRIMER_FIELD] [--prcons PRIMER_FREQ]
              [--cf COPY_FIELDS [COPY_FIELDS ...]]  [--act
              {min,max,sum,set,majority} [{min,max,sum,set,majority} ...]]
              [--dep] [--maxdiv MAX_DIVERSITY | --maxerror MAX_ERROR]

Builds a consensus sequence for each set of input sequences. It's giving main character energy โœจ


๐ŸŒธ help ๐ŸŒธ

  • --version โ€” shows the program's version number and then exits ๐ŸŽ€
  • -h, --help โ€” shows this help message and exits ๐Ÿงš

๐Ÿ“ standard arguments ๐Ÿ“

  • -s SEQ_FILES [SEQ_FILES ...] โ€” the list of FASTA/FASTQ files holding the sequences you want processed ๐Ÿ’– (default: None)
  • -o OUT_FILES [OUT_FILES ...] โ€” explicit output file name(s). Heads up, this one can't be used with --failed, --outdir, or --outname ๐Ÿ™ˆ If you don't set it, the output filename gets based on your input filename(s). (default: None)
  • --outdir OUT_DIR โ€” changes the output directory to wherever you point it. If you skip this, the input file directory is used instead ๐ŸŒˆ (default: None)
  • --outname OUT_NAME โ€” swaps the prefix of the successfully processed output file for the string you give it. Can't be used with multiple input files ๐Ÿ’… (default: None)
  • --log LOG_FILE โ€” writes verbose logging to a file. Also can't be used with multiple input files ๐Ÿ“ (default: None)
  • --failed โ€” creates files holding the records that fail processing ๐Ÿ’€ (default: False)
  • --fasta โ€” forces the output to be FASTA instead of FASTQ ๐Ÿฆ‹ (default: None)
  • --delim DELIMITER DELIMITER DELIMITER โ€” a list of three delimiters. In order, they separate annotation blocks, field names from values, and values within a field ๐Ÿซง (default: ('|', '=', ','))
  • --nproc NPROC โ€” how many computational processes run at the same time (aka how many CPU cores you want to utilize) ๐Ÿ”ฅ (default: 4)

๐Ÿงš consensus generation arguments ๐Ÿงš

  • -n MIN_COUNT โ€” the minimum number of sequences needed before a consensus counts as valid โœจ (default: 1)
  • --bf BARCODE_FIELD โ€” the position of the description barcode field you want to group sequences by ๐Ÿ“ (default: BARCODE)
  • -q MIN_QUAL โ€” the consensus quality score cut-off. Anything under it gets an ambiguous character assigned. It doesn't apply when quality scores aren't available ๐Ÿ™ˆ (default: 0)
  • --freq MIN_FREQ โ€” the fraction of character occurrences under which an ambiguous character gets assigned ๐Ÿ’œ (default: 0.6)
  • --maxgap MAX_GAP โ€” if you set this, it defines a cut-off for how often gap values are allowed at each position. Positions over the threshold get deleted from the consensus. If you don't define it, positions are always kept ๐Ÿซถ (default: None)
  • --pf PRIMER_FIELD โ€” the field name of the primer annotations ๐ŸŽ€ (default: None)
  • --prcons PRIMER_FREQ โ€” sets a minimum primer frequency needed to assign a consensus primer. It also filters out sequences with minority primers from the consensus building step ๐Ÿ‘‘ (default: None)
  • --cf COPY_FIELDS [COPY_FIELDS ...] โ€” extra annotation fields to copy into the consensus sequence annotations ๐ŸŒธ (default: None)
  • --act {min,max,sum,set,majority} [{min,max,sum,set,majority} ...] โ€” a list of actions, one for each copy field, that decides how each annotation gets combined into a single value ๐Ÿ’…
    • min, max, and sum do the matching math operation on numeric annotations ๐Ÿงฎ
    • set mashes the annotations into a comma delimited list of unique values, and adds an annotation named <FIELD>_COUNT with the count of each item in the set ๐Ÿ“
    • majority gives the consensus annotation the most frequent annotation, and adds an annotation named <FIELD>_FREQ with the frequency of that majority value ๐Ÿ‘‘

(default: None)

  • --dep โ€” calculates consensus quality with a nonindependence assumption ๐Ÿง  (default: False)
  • --maxdiv MAX_DIVERSITY โ€” calculates the nucleotide diversity of each read group (average pairwise error rate) and removes groups going over the diversity threshold. The diversity is calculated for all positions in the read group, ignoring any character filtering from -q, --freq and --maxgap ๐Ÿ™…โ€โ™€๏ธ Mutually exclusive with --maxerror. (default: None)
  • --maxerror MAX_ERROR โ€” calculates the error rate of each read group (the rate of mismatches from the consensus) and removes groups over the error threshold. The error rate is calculated against the final consensus, which can include masked positions because of -q and --freq, and can have deleted positions because of --maxgap ๐Ÿšซ Mutually exclusive with --maxdiv. (default: None)

๐ŸŒˆ output files ๐ŸŒˆ

  • consensus-pass โ€” the consensus reads ๐Ÿซง
  • consensus-fail โ€” the raw reads that fail the consensus filtering criteria ๐Ÿ’€

๐Ÿ’œ output annotation fields ๐Ÿ’œ

  • PRIMER โ€” a comma delimited list of the unique primer annotations found within the barcode read group ๐ŸŽ€
  • PRCOUNT โ€” a comma delimited list of the matching counts for those unique primer annotations ๐Ÿ”ข
  • PRCONS โ€” the majority primer within the barcode read group ๐Ÿ‘‘
  • PRFREQ โ€” the frequency of the majority primer ๐Ÿ“ˆ
  • CONSCOUNT โ€” the count of reads in the barcode read group that actually went into the consensus sequence. It's the total size of the read group minus any sequence excluded by your filtering criteria ๐Ÿง

๐Ÿซถ AUTHOR ๐Ÿซถ

This manpage was written by Andreas Tille for the Debian distribution and can be used for any other usage of the program ๐ŸŒท


Bestie, that's the whole tea โ˜•๐Ÿ’– BuildConsensus.py 0.6.0, May 2020, and we're signing off with main character energy ๐Ÿฆ‹โœจ