view compare_gff.xml @ 12:755a4d643184 draft default tip

planemo upload commit a61591d548f42ff417781e7fe7418dc2901ccc23
author petr-novak
date Tue, 26 Sep 2023 07:28:04 +0000
parents 5366d5ea04bc
children
line wrap: on
line source

<tool id="compare_gff" name="Compare overlap of two GFF3" version="0.1.0"
      python_template_version="3.5">
    <requirements>
        <requirement type="package">bioconductor-rtracklayer</requirement>
    </requirements>
    <required_files>
        <include type="literal" path="compare_gff.R"/>
    </required_files>
    <command detect_errors="exit_code"><![CDATA[
        Rscript '$__tool_directory__'/compare_gff.R '$input1_gff' '$input2_gff' '$attribute_name'
        &&
        cp annotation_overlap_long.csv '$out_long'
        &&
        cp annotation_overlap.csv '$out_wide'

    ]]></command>
    <inputs>
        <param type="data" name="input1_gff" format="gff" label="First GFF">
            <sanitizer invalid_char="">
                <valid initial="string.ascii_letters,string.digits">
                    <add value="_"/>
                </valid>
            </sanitizer>
        </param>
        <param type="data" name="input2_gff" format="gff" label="Second GFF">
            <sanitizer invalid_char="">
                <valid initial="string.ascii_letters,string.digits">
                    <add value="_"/>
                </valid>
            </sanitizer>
        </param>
        <param type="text" name="attribute_name" label="Name of attribute to summarize"
               optional="false" default="Name"/>
    </inputs>
    <outputs>
        <data name="out_long" format="tabular" label="Overlap of annotations
        ${input1_gff.hid} and ${input1_gff.hid} (as matrix)"/>
        <data name="out_wide" format="tabular" label="Overlap of annotations
        ${input1_gff.hid} and ${input1_gff.hid} (as table)"/>
    </outputs>
    <help><![CDATA[
        Compare overlaps in two GFF3 by selected attribute. Overlap is reported a number of bases. It expects not overlap within individuals GFF3.
    ]]></help>
</tool>