view jaccardBed.xml @ 41:7ab85ac5f64b draft

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/bedtools commit 500a03281ea704abc7a16d9af63d67dbdcc5cd0b"
author iuc
date Thu, 04 Nov 2021 11:36:55 +0000
parents 3e38c9b3214f
children 64e2edfe7a2c
line wrap: on
line source

<tool id="bedtools_jaccard" name="bedtools JaccardBed" version="@TOOL_VERSION@" profile="@PROFILE@">
    <description>calculate the distribution of relative distances between two files</description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="bio_tools" />
    <expand macro="requirements" />
    <expand macro="stdio" />
    <command><![CDATA[
bedtools jaccard
$strand
$split
$reciprocal
@OVERLAP@
#if str($overlapB):
   -F $overlapB
#end if
-a '$inputA'
-b '$inputB'
> '$output'
    ]]></command>
    <inputs>
        <param name="inputA" argument="-a" type="data" format="@STD_BEDTOOLS_INPUTS@" label="@STD_BEDTOOLS_INPUT_LABEL@ file"/>
        <param name="inputB" argument="-b" type="data" format="@STD_BEDTOOLS_INPUTS@" label="@STD_BEDTOOLS_INPUT_LABEL@ file"/>
        <expand macro="overlap" />
        <expand macro="overlap" name="overlapB" argument="-F" fracof="B"/>
        <expand macro="reciprocal" />
        <param name="strand" argument="-s" type="boolean" truevalue="-s" falsevalue="" checked="false"
            label="Force strandedness"
            help="That is, only report hits in B that overlap A on the same strand. By default, overlaps are reported without respect to strand." />
        <expand macro="strand2" />
        <expand macro="split" />
    </inputs>
    <outputs>
        <data name="output" format_source="inputA" metadata_source="inputA" label="Intersection of ${inputA.name} and ${inputB.name}" />
    </outputs>
    <tests>
        <test>
            <param name="inputA" value="jaccardBed1.bed" ftype="bed" />
            <param name="inputB" value="jaccardBed2.bed" ftype="bed" />
            <output name="output" file="jaccardBed_result1.bed" ftype="bed" />
        </test>
        <test>
            <param name="inputA" value="jaccardBed1.bed" ftype="bed" />
            <param name="inputB" value="jaccardBed2.bed" ftype="bed" />
            <param name="overlap" value="0.1" />
            <output name="output" file="jaccardBed_result2.bed" ftype="bed" />
        </test>
    </tests>
    <help><![CDATA[
**What it does**

By default, bedtools jaccard reports the length of the intersection, the length of the union (minus the intersection), the final Jaccard statistic reflecting the similarity of the two sets, as well as the number of intersections.
Whereas the bedtools intersect tool enumerates each an every intersection between two sets of genomic intervals, one often needs a single statistic reflecting the similarity of the two sets based on the intersections between them. The Jaccard statistic is used in set theory to represent the ratio of the intersection of two sets to the union of the two sets. Similarly, Favorov et al [1] reported the use of the Jaccard statistic for genome intervals: specifically, it measures the ratio of the number of intersecting base pairs between two sets to the number of base pairs in the union of the two sets. The bedtools jaccard tool implements this statistic, yet modifies the statistic such that the length of the intersection is subtracted from the length of the union. As a result, the final statistic ranges from 0.0 to 1.0, where 0.0 represents no overlap and 1.0 represent complete overlap.

.. image:: $PATH_TO_IMAGES/jaccard-glyph.png

.. class:: warningmark

The jaccard tool requires that your data is pre-sorted by chromosome and then by start position (e.g., sort -k1,1 -k2,2n in.bed > in.sorted.bed for BED files).

@REFERENCES@
    ]]></help>
    <expand macro="citations" />
</tool>