view macros.xml @ 5:6ba59950d95c draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/mothur commit 7f7605c2c8d8e92f3369dfdc290e5d8d06fa409a
author iuc
date Fri, 03 Aug 2018 14:39:11 -0400
parents 085625ddf82c
children 14e978a6ffdf
line wrap: on
line source

<macros>
    <token name="@WRAPPER_VERSION@">1.39.5</token>
    <xml name="requirements">
        <requirements>
            <requirement type="package" version="@WRAPPER_VERSION@">mothur</requirement>
            <yield/>
        </requirements>
    </xml>
    <xml name="version_command">
        <version_command><![CDATA[ mothur "#help()" | sed '7q;d' | cut -d" " -f2 ]]></version_command>
    </xml>
    <xml name="stdio">
        <stdio>
            <regex match="\[ERROR\]" source="stdout" level="fatal"/>
            <exit_code range="1:" level="fatal"/>
        </stdio>
    </xml>
    <token name="@SHELL_OPTIONS@">set -o pipefail;</token>


    <!-- Input parameters -->
    <xml name="labeloptions">
        <options>
            <filter type="data_meta" ref="otu" key="labels"/>
        </options>
    </xml>
    <xml name="calc-common">
        <!-- you can set defaults in tool xml by repeating those options again after macro expand, overriding first -->
        <option value="anderberg">anderberg - Community Membership Similarity the Anderberg similarity coefficient</option>
        <option value="braycurtis">braycurtis - Community Structure Similarity the Bray-Curtis similarity coefficient</option>
        <option value="canberra">canberra - Community Structure Similarity</option>
        <option value="gower">gower - Community Structure Similarity</option>
        <option value="hamming">hamming - Community Membership Similarity</option>
        <option value="hellinger">hellinger - Community Structure Similarity</option>
        <option value="jabund">jabund - Community Structure Similarity the abundance-based Jaccard similarity coefficient</option>
        <option value="jclass">jclass - Community Membership Similarity the traditional Jaccard similarity coefficient based on the observed richness</option>
        <option value="jest">jest - Community Membership Similarity the Jaccard similarity coefficient based on the Chao1 estimated richnesses</option>
        <option value="jsd">jsd</option>
        <option value="kulczynski">kulczynski - Community Membership Similarity the Kulczynski similarity coefficient</option>
        <option value="kulczynskicody">kulczynskicody - Community Membership Similarity the Kulczynski-Cody similarity coefficient</option>
        <option value="kstest">kstest - Community Membership Similarity Kolmogorov-Smirnov test</option>
        <option value="lennon">lennon - Community Membership Similarity the Lennon similarity coefficient</option>
        <option value="manhattan">manhattan - Community Structure Similarity</option>
        <option value="memchi2">memchi2 - Community Membership Similarity</option>
        <option value="memchord">memchord - Community Membership Similarity</option>
        <option value="memeuclidean">memeuclidean - Community Membership Similarity</option>
        <option value="mempearson">mempearson - Community Membership Similarity</option>
        <option value="morisitahorn">morisitahorn - Community Structure Similarity the Morisita-Horn similarity coefficient</option>
        <option value="ochiai">ochiai - Community Membership Similarity the Ochiai similarity coefficient</option>
        <option value="odum">odum - Community Structure Similarity</option>
        <option value="rjsd">rjsd</option>
        <option value="sharedace">sharedace - Shared community richness the two sample shared ACE richness estimator</option>
        <option value="sharednseqs">sharednseqs - Utility the number of sequences in two samples</option>
        <option value="sharedobserved">sharedobserved - Utility the number of sequences in two samples</option>
        <option value="sharedsobs">sharedsobs - Shared community richness the observed richness shared between two or more samples</option>
        <option value="sharedchao">sharedchao - Shared community richness the two or more sample shared Chao1 richness estimator</option>
        <option value="soergel">soergel - Community Structure Similarity</option>
        <option value="sorabund">sorabund - Community Structure Similarity the abundance-based Sorenson similarity coefficient</option>
        <option value="sorclass">sorclass - Community Membership Similarity the Sorenson similarity coefficient based on the observed richness</option>
        <option value="sorest">sorest - Community Membership Similarity the Sorenson similarity coefficient based on the Chao1 estimated richnesses</option>
        <option value="spearman">spearman - Community Structure Similarity</option>
        <option value="speciesprofile">speciesprofile - Community Structure Similarity</option>
        <option value="structchi2">structchi2 - Community Structure Similarity</option>
        <option value="structchord">structchord - Community Structure Similarity</option>
        <option value="structeuclidean">structeuclidean - Community Structure Similarity</option>
        <option value="structkulczynski">structkulczynski - Community Structure Similarity</option>
        <option value="structpearson">structpearson - Community Structure Similarity</option>
        <option value="thetan">thetan - Community Structure Similarity the Smith theta similarity coefficient</option>
        <option value="thetayc">thetayc - Community Structure Similarity the Yue &amp; Clayton theta similarity coefficient</option>
        <option value="whittaker">whittaker - Community Membership Similarity the Whittaker similarity coefficient</option>
        <yield/>
    </xml>

    <!-- CLUSTERING -->
    <xml name="param-clustermethods">
        <param argument="method" type="select" label="Clustering Method">
            <option value="opti" selected="true">Opticlust method</option>
            <option value="furthest">Furthest neighbor</option>
            <option value="nearest">Nearest neighbor</option>
            <option value="average">Average neighbor</option>
            <yield/>
        </param>
    </xml>
    <xml name="option-vsearch-clustermethods">
        <option value="agc">Abundance-based greedy clustering (agc)(VSEARCH)</option>
        <option value="dgc">Distance-based greedy clustering (dgc)(VSEARCH)</option>
    </xml>
    <xml name="params-opticlust">
        <param argument="metric" type="select" label="metric - select the metric in the opticluster method"
            help="Options are Matthews correlation coefficient (mcc), sensitivity (sens), specificity (spec), true positives + true negatives (tptn),
            false positives + false negatives (fpfn), true positives (tp), true negative (tn), false positive (fp), false negative (fn), f1score (f1score),
            accuracy (accuracy), positive predictive value (ppv), negative predictive value (npv), false discovery rate (fdr). Default=mcc.">
            <option value="mcc" selected="true">Matthews correlation coefficient (mcc)</option>
            <option value="sens">Sensitivity</option>
            <option value="spec">specificity</option>
            <option value="tptn">true positives + true negatives</option>
            <option value="fpfn">false positives + false negatives</option>
            <option value="tp">true positives</option>
            <option value="tn">true negative</option>
            <option value="fp">false positive</option>
            <option value="fn">false negative</option>
            <option value="f1score">f1score</option>
            <option value="accuracy">accuracy</option>
            <option value="ppv">positive predictive value</option>
            <option value="npv">negative predictive value</option>
            <option value="fdr">false discovery rate</option>
        </param>
        <param argument="initialize" type="select" label="Initial randomization"
            help="singleton: each sequence is randomly assigned to its own OTU; oneotu: all sequences are assigned to one otu">
            <option value="singleton" selected="true">Singleton</option>
            <option value="oneotu">Oneotu</option>
        </param>
        <param argument="delta" type="float" value="0.0001" label="set the stable value for the metric in the opticluster method"
            help="The delta parameter allows to set the stable value for the metric in the opticluster method. To reach a full convergence, set delta=0."/>
        <param argument="iters" type="integer" value="100" label="Maximum number of iterations"/>
    </xml>
    <xml name="param-output">
        <param argument="output" type="select" label="Tax summary output type"
            help="The detail format outputs the totals at each level, where as the simple format outputs the highest level">
            <option value="simple" selected="true">simple</option>
            <option value="detail">detail</option>
        </param>
    </xml>
    <xml name="param-printlevel">
        <param argument="printlevel" type="integer" value="-1" min="-1" label="Print level" help="specify taxlevel of your *tax.summary file to print to. Options are 1 to the maz level in the file. The default is -1, meaning max level" />
    </xml>
    <xml name="param-savelog">
        <param name="savelog" type="boolean" checked="false" label="Output logfile?"/>
    </xml>
    <xml name="logfile-output">
        <data name="logfile" format="txt" from_work_dir="mothur.out.log" label="${tool.name} on ${on_string}: logfile">
            <filter>savelog</filter>
        </data>
    </xml>

    <!-- Output file tests -->
    <xml name="logfile-test">
        <output name="logfile" ftype="txt">
            <assert_contents>
                <has_text text="mothur"/>
                <has_text text="@WRAPPER_VERSION@"/>
            </assert_contents>
        </output>
    </xml>

    <xml name="test-accnos-format">
        <!-- one or two columns -->
        <has_line_matching expression="^[\w\d\-]+(\t[^\t]+)?$"/>
    </xml>
    <xml name="test-align-format">
        <has_line_matching expression="^>.+$"/>
        <has_line_matching expression="^[ACTG\-\.]+$"/>
    </xml>
    <xml name="test-aligncheck-format">
        <has_n_columns n="9"/>
        <has_line_matching expression="^name\tpound\tdash\tplus\tequal\tloop\ttilde\ttotal\tnumseqs$"/>
    </xml>
    <xml name="test-alignreport-format">
        <has_line_matching expression="^QueryName\tQueryLength\tTemplateName\tTemplateLength\tSearchMethod\tSearchScore\tAlignmentMethod\tQueryStart\tQueryEnd\tTemplateStart\tTemplateEnd\tPairwiseAlignmentLength\tGapsInQuery\tGapsInTemplate\tLongestInsert\tSimBtwnQuery&amp;Template$"/>
    </xml>
    <xml name="test-axes-format">
        <has_line_matching expression="^group(\taxis\d+)+$"/>
    </xml>
    <xml name="test-chimera-format">
        <has_line_matching expression="Score\tQuery\tParentA\tParentB\tIdQM\tIdQA\tIdQB\tIdAB\tIdQT\tLY\tLN\tLA\tRY\tRN\tRA\tDiv\tYN"/>
    </xml>
    <xml name="test-column-format">
        <has_n_columns n="3"/>
        <has_line_matching expression="^[\w\d\-]+\t[\w\d\-]+\t[\d\.]+$"/>
    </xml>
    <xml name="test-contigsreport-format">
        <has_n_columns n="7"/>
        <has_line_matching expression="^Name\tLength\tOverlap_Length\tOverlap_Start\tOverlap_End\tMisMatches\tNum_Ns$"/>
    </xml>
    <xml name="test-count-format">
        <has_line_matching expression="^Representative_Sequence\ttotal(\t\w+)*$"/>
        <has_line_matching expression="^\w+(\t\d+)+(\s)*$"/>
    </xml>
    <xml name="test-dist-format">
        <has_line_matching expression="^[ \t]*\d+$"/>
        <has_line_matching expression="^[\w\d\-]+(\t[\d\.]+)+\s?$"/>
    </xml>
    <xml name="test-fasta-format">
        <has_line_matching expression="^>.+$"/>
        <has_line_matching expression="^[ACTGN-]+$"/>
    </xml>
    <xml name="test-fastq-format">
        <has_line_matching expression="^@.+$"/>
        <has_line_matching expression="^[ACTGN]+$"/>
        <has_line_matching expression="^\+$"/>
    </xml>
    <xml name="test-group-format">
        <has_line_matching expression="^Representative_Sequence\ttotal(\t[\w\d\-]+)+$"/>
        <has_line_matching expression="^[\w\d\-]+(\t\d+)+$"/>
    </xml>
    <xml name="test-list-format">
        <has_line_matching expression="^label\tnumOtus(\tOtu\d+)+$"/>
        <has_line_matching expression="^(unique|0\.\d+)\t\d+(\t[\w\d\-,]+)+$"/>
    </xml>
    <xml name="test-names-format">
        <has_line_matching expression="^[a-zA-Z0-9]+\t[a-zA-Z0-9]+$"/>
    </xml>
    <xml name="test-qfile-format">
        <has_line_matching expression="^(\d+ )+$"/>
        <has_line_matching expression="^>.+$"/>
    </xml>
    <xml name="test-rabund-format">
        <has_line_matching expression="^(unique|0\.\d+)(\t\d+\.?\d*)+$"/>
    </xml>
    <xml name="test-sabund-format">
        <has_line_matching expression="^(unique|0\.\d+)(\t\d+)+$"/>
    </xml>
    <xml name="test-sensspec-format">
        <has_n_columns n="14"/>
        <has_line_matching expression="^label\tcutoff\ttp\ttn\tfp\tfn\tsensitivity\tspecificity\tppv\tnpv\tfdr\taccuracy\t\w+\tf1score$"/>
    </xml>
    <xml name="test-shared-format">
        <has_line_matching expression="^label\tGroup\tnumOtus(\t(Otu|rareOTUs|.*OTU.*)\d+)+$"/>
    </xml>
    <xml name="test-taxonomy-format">
        <has_n_columns n="3"/>
        <has_line_matching expression="^OTU\tSize\tTaxonomy$"/>
    </xml>
    <xml name="test-taxsummary-format">
        <has_line_matching expression="^((taxlevel\trankID\ttaxon\tdaughterlevels\ttotal(\t[\w\d\-]+)*)|(taxonomy\ttotal(\t[\w\d]+)*))$"/>
    </xml>
    <!-- backmatter -->
    <token name="@MOTHUR_OVERVIEW@">
<![CDATA[

**Mothur Overview**

Mothur is a comprehensive suite of tools for microbial ecology community. It is initiated by Dr. Patrick Schloss and his software development team
in the Department of Microbiology and Immunology at The University of Michigan. For more information, see Mothur-Wiki_.

.. _Mothur-Wiki: https://www.mothur.org/wiki/Main_Page

]]>
    </token>
    <xml name="citations">
        <citations>
            <citation type="doi">10.1128/AEM.01541-09</citation>
            <yield/>
        </citations>
    </xml>
    <xml name="citations-ecology">
        <citation type="bibtex">
            @book{mccune2002analysis,
              title={Analysis of ecological communities},
              author={McCune, Bruce and Grace, James B and Urban, Dean L},
              volume={28},
              year={2002},
              publisher={MjM software design Gleneden Beach, OR}
            }
        </citation>
        <citation type="bibtex">
            @misc{legendre1998numerical,
              title={Numerical Ecology, Volume 24, (Developments in Environmental Modelling)},
              author={Legendre, Pierre and Legendre, Louis},
              year={1998},
              publisher={Elsevier Science Amsterdam, The Netherlands}
            }
        </citation>
    </xml>
</macros>