diff tools/mothur/fastq.info.xml @ 0:ee4fee239fe7 draft default tip

planemo upload commit 68a4fd4cc5332c57ac39bef73db224425af0706c-dirty
author sanbi-uwc
date Fri, 03 Jun 2016 09:32:47 -0400
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tools/mothur/fastq.info.xml	Fri Jun 03 09:32:47 2016 -0400
@@ -0,0 +1,136 @@
+<tool profile="16.07" id="mothur_fastq_info" name="Fastq.info" version="@WRAPPER_VERSION@.0">
+    <description>Convert fastq to fasta and quality</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements"/>
+    <expand macro="version_command"/>
+    <command detect_errors="aggressive"><![CDATA[
+        echo 'fastq.info(
+            fastq=$fastq,
+            pacbio=$pacbio,
+            format=$format
+            #if $oligo.add == "yes":
+                ,oligos=$oligo.oligos
+                ,bdiffs=$oligo.bdiffs
+                ,pdiffs=$oligo.pdiffs
+                ,tdiffs=$oligo.tdiffs
+                ,ldiffs=$oligo.ldiffs
+                ,sdiffs=$oligo.sdiffs
+            #end if
+        )'
+        | sed 's/ //g'  ## mothur trips over whitespace
+        | mothur &&
+
+        ## move output files to correct destination
+        prefix="$fastq" &&
+        #if $oligo.add == "yes":
+            mv \${prefix%.dat}*.scrap.fastq "$fastq_scrap_out" &&
+            mv \${prefix%.dat}*.scrap.fasta "$fasta_scrap_out" &&
+            mv \${prefix%.dat}*.scrap.qual "$qfile_scrap_out" &&
+        #end if
+        mv \${prefix%.dat}*.fasta "$fasta_out" &&
+        mv \${prefix%.dat}*.qual "$qfile_out" &&
+        mv mothur.*.logfile "$logfile"
+    ]]></command>
+    <inputs>
+        <param name="fastq" type="data" format="fastq" label="fastq - Fastq Sequence file"/>
+        <param name="pacbio" type="boolean" truevalue="true" falsevalue="false" checked="false" label="pacbio - if set to true, quality scores of 0 will results in a corresponding base of N"/>
+        <param name="format" type="select" label="format of sequence">
+            <option value="sanger" selected="true">sanger</option>
+            <option value="solexa">solexa</option>
+            <option value="illumina">illumina</option>
+            <option value="illumina1.8+">illumina1.8+</option>
+        </param>
+        <conditional name="oligo">
+            <param name="add" type="select" label="Use oligos file?" help="a file that contain the sequences of the forward and reverse primers and barcodes and their sample identifier. Each line of the oligos file can start with the key words &quot;forward&quot;, &quot;reverse&quot;, and &quot;barcode&quot; or it can start with a &quot;#&quot; to tell mothur to ignore that line of the oligos file.">
+                <option value="no">no</option>
+                <option value="yes">yes</option>
+            </param>
+            <when value="yes">
+                <param name="oligos" type="data" format="mothur.oligos" label="oligos - barcodes and primers"/>
+                <param name="bdiffs" type="integer" value="0" min="0" label="bdiffs - number of differences to allow in the barcode (must be > 0; default 0)"/>
+                <param name="pdiffs" type="integer" value="0" min="0" label="pdiffs - number of differences to allow in the primer (must be > 0; default 0)"/>
+                <param name="tdiffs" type="integer" value="0" min="0" label="tdiffs - total number of differences to allow in primer and barcode (must be > 0; default 0)"/>
+                <param name="ldiffs" type="integer" value="0" min="0" label="ldiffs - total number of differences to allow in linker sequence (must be > 0; default 0)"/>
+                <param name="sdiffs" type="integer" value="0" min="0" label="sdiffs - total number of differences to allow in spacer sequence (must be > 0; default 0)"/>
+            </when>
+            <when value="no"/>
+        </conditional>
+    </inputs>
+    <outputs>
+        <data name="logfile" format="txt" label="${tool.name} on ${on_string}: logfile"/>
+        <data name="fasta_out" format="fasta" label="${tool.name} on ${on_string}: fasta"/>
+        <data name="qfile_out" format="qual454" label="${tool.name} on ${on_string}: qual"/>
+        <data name="fastq_scrap_out" format="fastq" label="${tool.name} on ${on_string}: fastq scrap">
+            <filter>oligos</filter>
+        </data>
+        <data name="fasta_scrap_out" format="fasta" label="${tool.name} on ${on_string}: fasta scrap">
+            <filter>oligos</filter>
+        </data>
+        <data name="qfile_scrap_out" format="qual454" label="${tool.name} on ${on_string}: qual scrap">
+            <filter>oligos</filter>
+        </data>
+    </outputs>
+    <tests>
+        <test>
+            <param name="fastq" value="Mock_S280_L001_R1_001_small.fastq"/>
+            <param name="pacbio" value="false"/>
+            <param name="format" value="sanger"/>
+            <param name="add" value="no"/>
+            <output name="fasta_out" md5="88c573d00181be6dd519a0c9599f8b0c"/>
+            <output name="qfile_out" md5="d382c496c583b1501666459757cabbe3"/>
+            <expand macro="logfile-test"/>
+        </test>
+        <test>
+            <param name="fastq" value="Mock_S280_L001_R1_001_small.fastq"/>
+            <param name="pacbio" value="false"/>
+            <param name="format" value="sanger"/>
+            <param name="add" value="yes"/>
+            <param name="oligos" value="GQY1XT001.oligos"/>
+            <param name="bdiffs" value="1"/>
+            <param name="pdiffs" value="3"/>
+            <param name="tdiffs" value="3"/>
+            <param name="ldiffs" value="3"/>
+            <param name="sdiffs" value="7"/>
+            <output name="fasta_out" md5="88c573d00181be6dd519a0c9599f8b0c" ftype="fasta"/>
+            <output name="qfile_out" md5="d382c496c583b1501666459757cabbe3" ftype="qual454"/>
+            <output name="fastq_scrap_out" md5="37a280b8af54af2a0a52b2eba1e58933" ftype="fastq"/>
+            <output name="fasta_scrap_out" md5="88c573d00181be6dd519a0c9599f8b0c" ftype="fasta"/>
+            <output name="qfile_scrap_out" md5="96c2f7ea3cf6336d50bef2c087280c01" ftype="qual454"/>
+            <expand macro="logfile-test"/>
+        </test>
+        <test>
+            <param name="fastq" value="Mock_S280_L001_R1_001_small.fastq"/>
+            <param name="pacbio" value="false"/>
+            <param name="format" value="sanger"/>
+            <param name="add" value="yes"/>
+            <param name="oligos" value="HMPv5-v3_1368-1369.oligos"/>
+            <param name="bdiffs" value="1"/>
+            <param name="pdiffs" value="3"/>
+            <param name="tdiffs" value="3"/>
+            <param name="ldiffs" value="3"/>
+            <param name="sdiffs" value="7"/>
+            <output name="fasta_out" md5="88c573d00181be6dd519a0c9599f8b0c"/>
+            <output name="qfile_out" md5="d382c496c583b1501666459757cabbe3"/>
+            <output name="fastq_scrap_out" md5="37a280b8af54af2a0a52b2eba1e58933"/>
+            <output name="fasta_scrap_out" md5="88c573d00181be6dd519a0c9599f8b0c"/>
+            <output name="qfile_scrap_out" md5="96c2f7ea3cf6336d50bef2c087280c01"/>
+            <expand macro="logfile-test"/>
+        </test>
+    </tests>
+    <help>
+<![CDATA[
+
+@MOTHUR_OVERVIEW@
+
+**Command Documenation**
+
+The fastq.info_ command reads a fastq file and creates a fasta and quality file.
+
+
+.. _fastq.info: http://www.mothur.org/wiki/Fastq.info
+]]>
+    </help>
+    <expand macro="citations"/>
+</tool>