diff correctGCBias.xml @ 13:b4c5dd45778a draft

Uploaded
author bgruening
date Mon, 16 Dec 2013 04:36:19 -0500
parents 135f3bae5c56
children 5ea8782d650c
line wrap: on
line diff
--- a/correctGCBias.xml	Sat Dec 14 08:58:41 2013 -0500
+++ b/correctGCBias.xml	Mon Dec 16 04:36:19 2013 -0500
@@ -5,91 +5,84 @@
     <macros>
         <import>deepTools_macros.xml</import>
     </macros>
-  <command>
-    #import tempfile
-    #set $temp_dir = os.path.abspath(tempfile.mkdtemp())
+    <command>
+        #import tempfile
+        #set $temp_dir = os.path.abspath(tempfile.mkdtemp())
 
-    #set $temp_bam_handle = tempfile.NamedTemporaryFile( dir=$temp_dir )
-    #set $temp_bam_path = $temp_bam_handle.name + '.bam'
-    #silent $temp_bam_handle.close()
-    #silent os.system("ln -s %s %s" % (str($bamInput), $temp_bam_path))
-    #silent os.system("ln -s %s %s.bai" % (str($bamInput.metadata.bam_index), $temp_bam_path))
+        #set $temp_bam_handle = tempfile.NamedTemporaryFile( dir=$temp_dir )
+        #set $temp_bam_path = $temp_bam_handle.name + '.bam'
+        #silent $temp_bam_handle.close()
+        #silent os.system("ln -s %s %s" % (str($bamInput), $temp_bam_path))
+        #silent os.system("ln -s %s %s.bai" % (str($bamInput.metadata.bam_index), $temp_bam_path))
 
 
-  correctGCBias
+        correctGCBias
 
-    @THREADS@
+        @THREADS@
 
-  --bamfile '$temp_bam_path'
-  --GCbiasFrequenciesFile $GCbiasFrequenciesFile
+        --bamfile '$temp_bam_path'
+        --GCbiasFrequenciesFile $GCbiasFrequenciesFile
 
-    @reference_genome_source@
+        @reference_genome_source@
 
 
-  #if $effectiveGenomeSize.effectiveGenomeSize_opt == "specific":
-    --effectiveGenomeSize $effectiveGenomeSize.effectiveGenomeSize
-  #else:
-    --effectiveGenomeSize $effectiveGenomeSize.effectiveGenomeSize_opt
-  #end if
-
+        #if $effectiveGenomeSize.effectiveGenomeSize_opt == "specific":
+            --effectiveGenomeSize $effectiveGenomeSize.effectiveGenomeSize
+        #else:
+            --effectiveGenomeSize $effectiveGenomeSize.effectiveGenomeSize_opt
+        #end if
 
-  #if $advancedOpt.showAdvancedOpt == "yes":
-    #if str($advancedOpt.region.value) != '':
-      --region '$advancedOpt.region'
-    #end if
-    
-    --binSize '$advancedOpt.binSize'  
-  #end if
-  
-  #set newoutFileName="corrected."+str($outFileFormat)
-  
-  --correctedFile $newoutFileName; mv $newoutFileName $outFileName
+        #if $advancedOpt.showAdvancedOpt == "yes":
+            #if str($advancedOpt.region.value) != '':
+                --region '$advancedOpt.region'
+            #end if
+            --binSize '$advancedOpt.binSize'  
+        #end if
 
-  </command>
-
-  <inputs>
+        #set newoutFileName="corrected."+str($outFileFormat)
+        --correctedFile $newoutFileName;
 
-  <param name="GCbiasFrequenciesFile" type="data" format="tabular" label="Output of computeGCBias" />
-
-  <param name="bamInput" format="bam" type="data" label="BAM file" help="This should be same file that was used for computeGCbias. The BAM file must be sorted."/>
-
+        mv $newoutFileName $outFileName
+    </command>
+    <inputs>
+        <param name="GCbiasFrequenciesFile" type="data" format="tabular" label="Output of computeGCBias" />
+        <param name="bamInput" format="bam" type="data" label="BAM file" help="This should be same file that was used for computeGCbias. The BAM file must be sorted."/>
         <expand macro="reference_genome_source" />
         <expand macro="effectiveGenomeSize" />
 
-  <param name="outFileFormat" type="select" label="File format of the output">
-    <option value="bam">bam</option>
-    <option value="bw">bigwig</option>
-    <option value="bg">bedgraph</option>
-  </param>
-  
-  <conditional name="advancedOpt">
-    <param name="showAdvancedOpt" type="select" label="Show advanced options" >
-        <option value="no" selected="true">no</option>
-        <option value="yes">yes</option>
-      </param>
-      <when value="no" />
-      <when value="yes">
-          <param name="region" type="text" value=""
-            label="Region of the genome to limit the operation to"
-            help="This is useful when testing parameters to reduce the computing time. The format is chr:start:end, for example &quot;chr10&quot; or &quot;chr10:456700:891000&quot;" />
-           
-           <param name="binSize" type="integer" value="50" min="1" 
-             label="Bin size in bp"
-             help="Size of the bins in bp for the ouput of the bigwig/bedgraph file."/>
-      </when>
-  </conditional>
-  </inputs>
-  
-  <outputs>
-    <data format="bam" name="outFileName">
-    <change_format>
-        <when input="outFileFormat" value="bw" format="bigwig" />
-        <when input="outFileFormat" value="bam" format="bam" />
-        <when input="outFileFormat" value="bg" format="bedgraph" />
-    </change_format>
-    </data>
-  </outputs>
-  <help>
+        <param name="outFileFormat" type="select" label="File format of the output">
+            <option value="bam">bam</option>
+            <option value="bw">bigwig</option>
+            <option value="bg">bedgraph</option>
+        </param>
+
+        <conditional name="advancedOpt">
+            <param name="showAdvancedOpt" type="select" label="Show advanced options" >
+                <option value="no" selected="true">no</option>
+                <option value="yes">yes</option>
+            </param>
+            <when value="no" />
+            <when value="yes">
+                <param name="region" type="text" value=""
+                    label="Region of the genome to limit the operation to"
+                    help="This is useful when testing parameters to reduce the computing time. The format is chr:start:end, for example &quot;chr10&quot; or &quot;chr10:456700:891000&quot;" />
+
+                <param name="binSize" type="integer" value="50" min="1" 
+                    label="Bin size in bp"
+                    help="Size of the bins in bp for the ouput of the bigwig/bedgraph file."/>
+            </when>
+        </conditional>
+    </inputs>
+    <outputs>
+        <data format="bam" name="outFileName">
+            <change_format>
+                <when input="outFileFormat" value="bw" format="bigwig" />
+                <when input="outFileFormat" value="bam" format="bam" />
+                <when input="outFileFormat" value="bg" format="bedgraph" />
+            </change_format>
+        </data>
+    </outputs>
+    <help>
 
 **What it does**