diff rarefaction.single.xml @ 0:ee20e83b2a92 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/mothur commit a9d1e0debcd357d8080a1c6c5f1d206dd45a7a4d
author iuc
date Fri, 19 May 2017 04:54:15 -0400
parents
children 871f24df79d8
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/rarefaction.single.xml	Fri May 19 04:54:15 2017 -0400
@@ -0,0 +1,106 @@
+<tool profile="16.07" id="mothur_rarefaction_single" name="Rarefaction.single" version="@WRAPPER_VERSION@.0">
+    <description>Generate intra-sample rarefaction curves for OTUs</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements"/>
+    <expand macro="stdio"/>
+    <expand macro="version_command"/>
+    <command><![CDATA[
+        @SHELL_OPTIONS@
+
+        ## create symlinks to input datasets
+        ln -s "$otu" otu.dat &&
+
+        echo 'rarefaction.single(
+            #if $otu.is_of_type("mothur.rabund"):
+                rabund=otu.dat,
+            #elif $otu.is_of_type("mothur.sabund"):
+                sabund=otu.dat,
+            #elif $otu.is_of_type("mothur.shared"):
+                shared=otu.dat,
+            #elif $otu.is_of_type("mothur.list"):
+                list=otu.dat,
+            #end if
+            #if $label:
+                label=${ str($label).replace(",","-") },
+            #end if
+            calc=${ str($calc).replace(",","-") },
+            abund=$abund,
+            iters=$iters,
+            freq=$freq,
+            processors='\${GALAXY_SLOTS:-8}'
+        )'
+        | sed 's/ //g'  ## mothur trips over whitespace
+        | mothur
+        | tee mothur.out.log
+
+        ## rename output from sobs calculator to be consistent with others
+        #if 'sobs' in str($calc).split(','):
+            && mv otu\.*rarefaction otu.r_sobs
+        #end if
+    ]]></command>
+    <inputs>
+        <param name="otu" type="data" format="mothur.list,mothur.rabund,mothur.sabund,mothur.shared" label="list,rabund,sabund,shared - OTU List"/>
+        <param name="label" type="select" label="label - OTU Labels" multiple="true">
+            <expand macro="labeloptions"/>
+        </param>
+        <param name="calc" type="select" label="calc - Calculators (Uses defaults if none selected)" multiple="true">
+            <option value="ace">ace - Community richness the ACE estimator</option>
+            <option value="bootstrap">bootstrap - Community richness the bootstrap estimator</option>
+            <option value="chao">chao - Community richness the Chao1 estimator</option>
+            <option value="jack">jack - Community richness the jackknife estimator</option>
+            <option value="sobs" selected="true">sobs - Community richness the observed richness</option>
+            <option value="simpsoneven">simpsoneven - Community evenness a Simpson index-based measure of evenness</option>
+            <option value="shannoneven">shannoneven - Community evenness a Shannon index-based measure of evenness</option>
+            <option value="heip">heip - Community evenness Heip's metric of community evenness</option>
+            <option value="smithwilson">smithwilson - Community evenness Smith and Wilson's metric of community evenness</option>
+            <option value="coverage">coverage - Community diversity the sampling coverage </option>
+            <option value="simpson">simpson - Community diversity the Simpson index</option>
+            <option value="invsimpson">invsimpson - Community diversity the Simpson index</option>
+            <option value="shannon">shannon - Community diversity the Shannon index</option>
+            <option value="npshannon">npshannon - Community diversity the non-parametric Shannon index</option>
+            <option value="nseqs">nseqs - Utility the number of sequences in a sample</option>
+        </param>
+        <param name="abund" type="integer" value="10" min="0" label="abund - ACE Estimator threshold for abundant versus rare OTUs"/>
+        <param name="iters" type="integer" value="1000" min="0" label="iters - Number of randomizations"/>
+        <param name="freq" type="float" value="100" min="0" max="100" label="freq - Reporting frequency" help="if between 0 and 1 the fraction of sequences to sample, if greater than one - report every n iterations"/>
+    </inputs>
+    <outputs>
+        <expand macro="logfile-output"/>
+        <collection name="rarefactioncurves" type="list" label="${tool.name} on ${on_string}: rarefaction curves">
+            <discover_datasets pattern=".*?(\.groups)?\.r_(?P&lt;designation&gt;.*)" format="tabular"/>
+        </collection>
+    </outputs>
+    <tests>
+        <test><!-- test with default values -->
+            <param name="otu" value="amazon.an.shared" ftype="mothur.shared"/>
+            <output_collection name="rarefactioncurves" count="1">
+                <element name="sobs" md5="c4c1f1970edf87ea5103e0704130f079" ftype="tabular"/>
+            </output_collection>
+            <expand macro="logfile-test"/>
+        </test>
+        <test><!-- test with all calculators and subset of labels -->
+            <param name="otu" value="amazon.an.shared" ftype="mothur.shared"/>
+            <param name="calc" value="ace,bootstrap,chao,jack,sobs,simpsoneven,shannoneven,heip,smithwilson,coverage,simpson,invsimpson,shannon,npshannon,nseqs"/>
+            <param name="label" value="0.03,0.05,0.36,0.55"/>
+            <output_collection name="rarefactioncurves" count="15">
+                <element name="simpson" md5="8d6b7ad9a68c30c882e93b17d343042a" ftype="tabular"/>
+            </output_collection>
+            <expand macro="logfile-test"/>
+        </test>
+    </tests>
+    <help>
+<![CDATA[
+
+@MOTHUR_OVERVIEW@
+
+**Command Documentation**
+
+The rarefaction.single_ command generates intra-sample rarefaction curves using a re-sampling without replacement approach. Rarefaction curves provide a way of comparing the richness observed in different samples.  For calc parameter choices see: https://www.mothur.org/wiki/Calculators
+
+.. _rarefaction.single: https://www.mothur.org/wiki/Rarefaction.single
+]]>
+    </help>
+    <expand macro="citations"/>
+</tool>