.. _`bio/rbt/collapse_reads_to_fragments-bam`: RBT COLLAPSE-READS-TO-FRAGMENTS BAM =================================== .. image:: https://img.shields.io/github/issues-pr/snakemake/snakemake-wrappers/bio/rbt/collapse_reads_to_fragments-bam?label=version%20update%20pull%20requests :target: https://github.com/snakemake/snakemake-wrappers/pulls?q=is%3Apr+is%3Aopen+label%3Abio/rbt/collapse_reads_to_fragments-bam Calculate consensus reads from read groups marked by PicardTools MarkDuplicates or UmiAwareMarkDuplicatesWithMateCigar. **URL**: https://github.com/rust-bio/rust-bio-tools Example ------- This wrapper can be used in the following way: .. code-block:: python rule calc_consensus_reads: input: "mapped/{sample}.marked.bam", output: consensus_r1="results/consensus/{sample}.1.fq", consensus_r2="results/consensus/{sample}.2.fq", consensus_se="results/consensus/{sample}.se.fq", skipped="results/consensus/{sample}.skipped.bam", params: extra="--annotate-record-ids", log: "logs/consensus/{sample}.log", wrapper: "v3.0.1/bio/rbt/collapse_reads_to_fragments-bam" Note that input, output and log file paths can be chosen freely. When running with .. code-block:: bash snakemake --use-conda the software dependencies will be automatically deployed into an isolated environment before execution. Software dependencies --------------------- * ``rust-bio-tools=0.42.0`` Authors ------- * Felix Mölder Code ---- .. code-block:: python __author__ = "Felix Mölder" __copyright__ = "Copyright 2022, Felix Mölder" __email__ = "felix.moelder@uk-essen.de" __license__ = "MIT" from snakemake.shell import shell log = snakemake.log_fmt_shell(stdout=True, stderr=True) extra = snakemake.params.get("extra", "") shell( "rbt collapse-reads-to-fragments bam {extra} {snakemake.input[0]} {snakemake.output} {log}" ) .. |nl| raw:: html