view make.lookup.xml @ 0:0c303113990d draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/mothur commit a9d1e0debcd357d8080a1c6c5f1d206dd45a7a4d
author iuc
date Fri, 19 May 2017 05:03:41 -0400
parents
children f338c64b09c1
line wrap: on
line source

<tool profile="16.07" id="mothur_make_lookup" name="Make.lookup" version="@WRAPPER_VERSION@.0">
    <description>allows you to create custom lookup files for use with shhh.flows</description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="requirements"/>
    <expand macro="stdio"/>
    <expand macro="version_command"/>
    <command><![CDATA[
        @SHELL_OPTIONS@

        #import re
        ## create symlinks to input datasets
        ln -s "$reference.template" reference.template.dat &&
        ln -s "$flow" flow.dat &&
        ln -s "$error" error.dat &&

        echo 'make.lookup(
            reference=reference.template.dat,
            flow=flow.dat,
            error=error.dat,
            order=$order,
            barcode=$re.sub("[^ACTG]","",str($barcode)),
            key=$re.sub("[^ACTG]","",str($key)),
            threshold=$threshold
        )'
        | sed 's/ //g'  ## mothur trips over whitespace
        | mothur
        | tee mothur.out.log
    ]]></command>
    <inputs>
        <conditional name="reference">
            <param name="source" type="select" label="Select Reference Template from" help="">
                <option value="hist">History</option>
                <option value="ref">Cached Reference</option>
            </param>
            <when value="ref">
                <param name="template" type="select" label="reference - Select an alignment database " help="">
                    <options from_data_table="mothur_aligndb"/>
                </param>
            </when>
            <when value="hist">
                <param name="template" type="data" format="fasta" label="reference - Reference to align with" help=""/>
            </when>
        </conditional>
        <param name="flow" type="data" format="motur.sff.flow" label="flow - provide file with flow data"/>
        <param name="error" type="data" format="tabular" label="error - provide the error summary" help="this file is an output of seq.error tool"/>
        <param name="order" type="select" label="order - flow order for nucleotides in the sequencer" help="default is A, was TACG. Also accepts B or I">
            <option value="A" selected="true">A (TACG)</option>
            <option value="B">B</option>
            <option value="I">I</option>
        </param>
        <param name="barcode" type="text" value="AACCGTGTC" label="barcode - provide the barcode sequence"/>
        <param name="key" type="text" value="TCAG" label="key - provide the key sequence"/>
        <param name="threshold" type="integer" value="10000" min="0" label="threshold - " help=""/>
    </inputs>
    <outputs>
        <expand macro="logfile-output"/>
        <data name="lookup_out" format="txt" from_work_dir="flow*.lookup" label="${tool.name} on ${on_string}: lookup"/>
    </outputs>
    <tests>
        <test><!-- test with defaults -->
            <param name="source" value="hist"/>
            <param name="template" value="HMP_MOCK.v35.align" ftype="mothur.align"/>
            <param name="flow" value="testflow.flow" ftype="mothur.sff.flow"/>
            <param name="error" value="Mock_S280_L001_R1_001_small.trim.contigs.good.error.summary" ftype="tabular"/>
            <output name="lookup_out" ftype="txt">
                <assert_contents>
                    <has_line_matching expression="^(-?[(\d\.|nan)]+\t?)+$"/>
                </assert_contents>
            </output>
            <expand macro="logfile-test"/>
        </test>
        <test><!-- test sanitizers -->
            <param name="source" value="hist"/>
            <param name="template" value="HMP_MOCK.v35.align" ftype="mothur.align"/>
            <param name="flow" value="testflow.flow" ftype="mothur.sff.flow"/>
            <param name="error" value="Mock_S280_L001_R1_001_small.trim.contigs.good.error.summary" ftype="tabular"/>
            <param name="barcode" value="XAXAXCXCXGXTXGXTXC"/><!-- should be converted to default value -->
            <param name="key" value="XTXCXAXGX"/><!-- should be converted to default value -->
            <output name="lookup_out" ftype="txt">
                <assert_contents>
                    <has_line_matching expression="^(-?[(\d\.|nan)]+\t?)+$"/>
                </assert_contents>
            </output>
            <expand macro="logfile-test"/>
        </test>
    </tests>
    <help>
<![CDATA[

@MOTHUR_OVERVIEW@

**Command Documentation**

The make.lookup_ allows you to create custom lookup files for use with shhh.flows.

.. _make.lookup: https://www.mothur.org/wiki/Make.lookup

]]>
    </help>
    <citations>
        <citation type="doi">10.1128/AEM.01541-09</citation>
    </citations>
</tool>