view samtools_bedcov.xml @ 2:12749212f61b draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_bedcov commit 411130b45dc30f7f24f41cdeec5e148c5d8faf40
author iuc
date Tue, 09 May 2017 11:17:25 -0400
parents 8c3472790020
children 9149ad20699a
line wrap: on
line source

<tool id="samtools_bedcov" name="BedCov" version="2.0.1">
    <description>calculate read depth for a set of genomic intervals</description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="requirements"/>
    <expand macro="stdio"/>
    <expand macro="version_command"/>
    <command><![CDATA[
        ## Ensure simlinks have unique filenames
        #for $i, $bam in enumerate( $input_bams ):
            ln -s -f '${bam}' '${i}.bam' &&
            ln -s -f '${bam.metadata.bam_index}' '${i}.bam.bai' &&
        #end for

        samtools bedcov
            '${input_bed}'
            #for $i in range(len( $input_bams )):
                '${i}.bam'
            #end for
            > '${output}'
    ]]></command>
    <inputs>
        <param name="input_bed" type="data" format="bed" label="Genemic intervals (in BED format)" />
        <param name="input_bams" type="data" format="bam" multiple="true" label="BAM file(s)" />
    </inputs>
    <outputs>
        <data name="output" format="tabular" label="${tool.name} on ${on_string}" />
    </outputs>
    <tests>
        <test>
            <param name="input_bed" value="eboVir3.1.bed" ftype="bed" />
            <param name="input_bams" value="eboVir3.bam" ftype="bam" />
            <output name="output" file="samtools_bedcov_out1.tab" />
        </test>
        <test>
            <param name="input_bed" value="eboVir3.1.bed" ftype="bed" />
            <param name="input_bams" value="eboVir3.bam,eboVir3.2.bam" ftype="bam" />
            <output name="output" file="samtools_bedcov_out2.tab" />
        </test>
    </tests>
    <help>
**What it does**

Calculates read depth for regions listed in a BED dataset using ``samtools bedcov`` command::

 samtools bedcov [INPUT BED] [INPUT BAM1] ... [INPUT BAMn] > [OUTPUT]
    </help>
    <expand macro="citations"/>
</tool>