diff bamPEFragmentSize.xml @ 52:c0a054f2eff8 draft

Uploaded
author bgruening
date Mon, 22 Dec 2014 18:56:27 -0500
parents 1d802a322244
children
line wrap: on
line diff
--- a/bamPEFragmentSize.xml	Thu Sep 18 16:58:56 2014 -0400
+++ b/bamPEFragmentSize.xml	Mon Dec 22 18:56:27 2014 -0500
@@ -9,19 +9,17 @@
     <command>
 <![CDATA[
         bamPEFragmentSize
-
-        @THREADS@
-
-        --bam '$bamInput'
-        --bamIndex ${bamInput.metadata.bam_index}
-        #if $histogram:
-            --histogram $histogram_outfile
-        #end if
-        > $outfile
-
+            @THREADS@
+            -bai ${bamInput.metadata.bam_index}
+            #if $histogram:
+                --histogram ./hist.png
+            #end if
+            '$bamInput'
+            > $outfile
+        &&
+        mv ./hist.png $histogram_outfile
 ]]>
     </command>
-
     <inputs>
         <param name="bamInput" format="bam" type="data" label="BAM file"
             help="The BAM file must be sorted."/>
@@ -30,13 +28,21 @@
             help="(--histogram)"/>
     </inputs>
     <outputs>
-        <data format="txt" name="outfile" label="${tool.name} on ${on_string}" />
-        <data name="histogram_outfile" format="tabular" from_work_dir="quant_bias_corrected.sf" label="${tool.name} on ${on_string} (Bias corrected Quantification)">
-            <filter>histogram == '--histogram'</filter>
+        <data name="outfile" format="txt"/>
+        <data name="histogram_outfile" format="png">
+            <filter>histogram is True</filter>
         </data>
     </outputs>
+    <tests>
+        <test>
+            <param name="bamInput" value="bowtie2-test1.bam" ftype="bam" />
+            <param name="histogram" value="True" />
+            <output name="outfile" file="bamPEFragmentSize_result1.txt" ftype="txt" />
+            <output name="histogram_outfile" file="bamPEFragmentSize_histogram_result1.png" ftype="png" />
+        </test>
+    </tests>
     <help>
-
+<![CDATA[
 **What it does**
 
 Given a BAM file it samples several regions to estimate the paird-end fragment length.
@@ -44,7 +50,7 @@
 -----
 
 @REFERENCES@
-
+]]>
     </help>
     <expand macro="citations" />
 </tool>