Mercurial > repos > bgruening > sambamba_flagstat
changeset 0:707d1578e0ec draft default tip
planemo upload for repository https://github.com/biod/sambamba commit 99bb4ed496a9cce79ab0a7e613230cf63a44d9f9
author | bgruening |
---|---|
date | Mon, 10 Feb 2025 19:12:11 +0000 |
parents | |
children | |
files | Sambamba_flagstat.xml macros.xml test-data/1.bam test-data/1.coord.sorted.bam test-data/1.qname.sorted.bam test-data/2.bam test-data/2.markdup.bam test-data/2.markdup.txt test-data/2.markdup_removed.bam test-data/coordinate_sorted.bam test-data/coordinate_sorted_merged.bam test-data/qname_sorted.bam test-data/qname_sorted_merged.bam |
diffstat | 13 files changed, 75 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Sambamba_flagstat.xml Mon Feb 10 19:12:11 2025 +0000 @@ -0,0 +1,45 @@ +<tool id="sambamba_flagstat" name="Sambamba flagstat" version="@TOOL_VERSION@+galaxy@SUFFIX_VERSION@" profile="23.2" license="MIT"> + <description>Retrieving flag statistics from BAM file</description> + <macros> + <import>macros.xml</import> + </macros> + <expand macro="requirements"/> + <command detect_errors="exit_code"><![CDATA[ + sambamba flagstat + '${input_bam}' + --nthreads \${GALAXY_SLOTS:-4} + > $output + ]]></command> + <inputs> + <param name="input_bam" type="data" format="bam" label="Input BAM file"/> + </inputs> + <outputs> + <data name="output" format="txt" metadata_source="input_bam"/> + </outputs> + <tests> + <test expect_num_outputs="1"> + <param name="input_bam" value="1.bam" ftype="bam"/> + <output name="output" md5="7df76f07273f8e35c542831a3f8c4dde"/> + </test> + </tests> + <help> +<![CDATA[ + +Sambamba_flagstat outputs statistics drawn from read flags. + +The first line contains numbers of QC-passed and QC-failed reads. Then come pairs of numbers, the former for QC-passed reads, the latter for QC-failed ones: + - duplicates + - mapped reads (plus percentage relative to the numbers from the first line) + - reads with 'is_paired' flag set + - paired reads which are first mates + - paired reads which are second mates + - paired reads with 'proper_pair' flag set (plus percentage relative to the numbers of QC-passed/failed reads with 'is_paired' flag set) + - paired reads where both mates are mapped + - paired reads where read itself is unmapped but mate is mapped + - paired reads where mate is mapped to a different chromosome + - the same as previous but mapping quality is not less than 5 + +]]> + </help> + <expand macro="citations" /> +</tool>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/macros.xml Mon Feb 10 19:12:11 2025 +0000 @@ -0,0 +1,17 @@ +<macros> + <token name="@TOOL_VERSION@">1.0.1</token> + <token name="@SUFFIX_VERSION@">2</token> + <xml name="requirements"> + <requirements> + <requirement type="package" version="1.0.1">sambamba</requirement> + <yield/> + </requirements> + </xml> + + <xml name="citations"> + <citations> + <citation type="doi">10.1093/bioinformatics/btv098</citation> + <yield /> + </citations> + </xml> +</macros>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test-data/2.markdup.txt Mon Feb 10 19:12:11 2025 +0000 @@ -0,0 +1,13 @@ + +sambamba 1.0.1 + by Artem Tarasov and Pjotr Prins (C) 2012-2023 + LDC 1.39.0 / DMD v2.109.1 / LLVM17.0.6 / bootstrap LDC - the LLVM D compiler (1.39.0) + +finding positions of the duplicate reads in the file... + sorted 0 end pairs + and 4 single ends (among them 0 unmatched pairs) + collecting indices of duplicate reads... done in 0 ms + found 3 duplicates +collected list of positions in 0 min 0 sec +marking duplicates... +collected list of positions in 0 min 0 sec