view bedtools-galaxy/coverageBed_counts.xml @ 1:41bba3e648d1 default tip

Deleted selected files
author aaronquinlan
date Thu, 29 Dec 2011 10:20:44 -0500
parents 26c21c634c51
children
line wrap: on
line source

<tool id="bedtools_coveragebed_counts" name="Count intervals in one file overlapping intervals in another file" version="0.1.0">

<description>
</description>

<requirements>
    <requirement type="binary">coverageBed</requirement>
</requirements>

<command>
    coverageBed
    #if $inputA.ext == "bam"
        -abam '$inputA'
    #else
        -a '$inputA'
    #end if
    -b '$inputB'
    -counts
    $split
    $strand
    | sort -k1,1 -k2,2n
    &gt; '$output'
</command>

<inputs>
    <param format="bed,bam" name="inputA" type="data" label="Count how many intervals in this BED or BAM file (source)">
          <validator type="unspecified_build" />
    </param>
    <param format="bed" name="inputB" type="data" label="overlap the intervals in this BED file (target)">
          <validator type="unspecified_build" />
    </param>
    <param name="split" type="boolean" checked="false" truevalue="-split" falsevalue="" label="Treat split/spliced BAM or BED12 entries as distinct BED intervals when computing coverage." help="If set, the coverage will be calculated based the spliced intervals only. For BAM files, this inspects the CIGAR N operation to infer the blocks for computing coverage. For BED12 files, this inspects the BlockCount, BlockStarts, and BlockEnds fields (i.e., columns 10,11,12). If this option is not set, coverage will be calculated based on the interval's START/END coordinates, and would include introns in the case of RNAseq data." />
    
    <param name="strand" type="select" label="Count">
        <option value="">overlaps on either strand</option>
        <option value="-s">only overlaps occurring on the **same** strand.</option>
        <option value="-S">only overlaps occurring on the **opposite** strand.</option>
    </param>
</inputs>

<outputs>
    <data format="bed" name="output" metadata_source="inputB" label="count of overlaps in ${inputA.name} on ${inputB.name}"/>
</outputs>

<help>

**What it does**

This tool converts counts the number of intervals in a BAM or BED file (the source) that overlap another BED file (the target).

.. class:: infomark

The output file will be comprised of each interval from your original target BED file, plus an additional column indicating the number of intervals in your source file that overlapped that target interval.

.. class:: warningmark

This tool requires that `bedtools`__ has been installed on your system.

------

This tool is part of the `bedtools package`__ from the `Quinlan laboratory`__. If you use this tool, please cite `Quinlan AR, and Hall I.M. BEDTools: A flexible framework for comparing genomic features. Bioinformatics, 2010, 26, 6.`__

    .. __: http://code.google.com/p/bedtools/
    .. __: http://code.google.com/p/bedtools/
    .. __: http://cphg.virginia.edu/quinlan/
    .. __: http://bioinformatics.oxfordjournals.org/content/26/6/841.short

</help>
</tool>