diff jcvi_gff_stats.xml @ 0:2defe48e4c7a draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/jcvi_gff_stats commit f1e2c895bec4b8bf960d54f634c69fe18411846a
author iuc
date Thu, 02 Aug 2018 09:57:30 -0400
parents
children 8cffbd184762
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/jcvi_gff_stats.xml	Thu Aug 02 09:57:30 2018 -0400
@@ -0,0 +1,91 @@
+<?xml version="1.0"?>
+<tool id="jcvi_gff_stats" name="Genome annotation statistics" profile="16.04" version="@VERSION@">
+    <description></description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements"/>
+    <command><![CDATA[
+
+        ln -s '${gff}' 'input.gff'
+
+        &&
+
+        python -m jcvi.annotation.stats genestats 'input.gff' > '${summary}'
+
+        &&
+
+        #if str($ref_genome.genome_type_select) == "indexed":
+            python -m jcvi.annotation.stats summary 'input.gff' '${ref_genome.genome.fields.path}' 2>&1 | tail -n +3 >> '${summary}'
+        #else
+            python -m jcvi.annotation.stats summary 'input.gff' '${ref_genome.genome}' 2>&1 | tail -n +3 >> '${summary}'
+        #end if
+
+        &&
+
+        python -m jcvi.annotation.stats stats 'input.gff' 2>&1 | grep Mean >> '${summary}'
+
+        &&
+
+        python -m jcvi.annotation.stats histogram 'input.gff'
+
+        &&
+
+        pdfunite *.input.pdf '${graphs}'
+    ]]></command>
+    <inputs>
+        <param name="gff" type="data" format="gff" label="Annotation to analyse"/>
+        <conditional name="ref_genome">
+            <param label="Reference genome" name="genome_type_select" type="select">
+                <option selected="True" value="indexed">Use a built-in genome</option>
+                <option value="history">Use a genome from history</option>
+            </param>
+            <when value="indexed">
+                <param
+                  help="If your genome of interest is not listed, contact the Galaxy server administrators"
+                  label="Select a reference genome"
+                  name="genome"
+                  type="select"
+                  >
+                    <options from_data_table="all_fasta">
+                        <filter column="2" type="sort_by" />
+                        <validator message="No genomes are available" type="no_options" />
+                    </options>
+                </param>
+            </when>
+            <when value="history">
+                  <param name="genome" type="data" format="fasta" label="Corresponding genome sequence"/>
+            </when>
+        </conditional>
+    </inputs>
+    <outputs>
+        <data format="txt" name="summary" label="${tool.name} on ${on_string}: summary"/>
+        <data format="pdf" name="graphs" label="${tool.name} on ${on_string}: gene length"/>
+    </outputs>
+    <tests>
+        <test>
+            <param name="gff" value="annot.gff3"/>
+            <conditional name="ref_genome">
+                <param name="genome_type_select" value="history"/>
+                <param name="genome" value="genome.fasta"/>
+            </conditional>
+            <output name="summary" file="summary.txt"/>
+            <output name="graphs" file="all.pdf" compare="sim_size"/>
+        </test>
+        <test>
+            <param name="gff" value="annot.gff3"/>
+            <conditional name="ref_genome">
+                <param name="genome_type_select" value="indexed"/>
+                <param name="genome" value="merlin"/>
+            </conditional>
+            <output name="summary" file="summary.txt"/>
+            <output name="graphs" file="all.pdf" compare="sim_size"/>
+        </test>
+    </tests>
+    <help><![CDATA[
+        Based on JCVI Python utility libraries on genome assembly, annotation and comparative genomics.
+
+        .. _JCVI Python utilities: https://github.com/tanghaibao/jcvi
+    ]]></help>
+    <expand macro="citations"/>
+</tool>