diff tracy_decompose.xml @ 0:6ec40b104f9d draft default tip

"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/tracy commit 8a1c82789c6ef97008ecf8f55e060422fd72f217"
author iuc
date Tue, 12 Oct 2021 14:21:06 +0000
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tracy_decompose.xml	Tue Oct 12 14:21:06 2021 +0000
@@ -0,0 +1,124 @@
+<tool id="tracy_decompose" name="tracy Decompose" version="@TOOL_VERSION@+galaxy0" profile="20.09">
+    <description>heterozygous mutations (and call variants)</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>    
+    <expand macro="requirements" /> 
+    <expand macro="version_command" />
+    <command detect_errors="exit_code"><![CDATA[
+        #if $index_genome == True
+            bgzip -c '$genome' > genome.fasta.gz ;
+            tracy index -o genome.fasta.fm9 genome.fasta.gz &&
+            #set refgenome = "genome.fasta.gz"
+        #else
+            #set refgenome = $genome
+        #end if
+        tracy decompose 
+          --genome '$refgenome'
+          $callVariants
+          --pratio $pratio 
+          --kmer $kmer.kmer 
+          --support $kmer.support 
+          --maxindel $maxindel 
+          --trim $trim.trim 
+          --trimLeft $trim.trimLeft 
+          --trimRight $trim.trimRight 
+          --linelimit $linelimit 
+          --gapopen $alignment.gapopen
+          --gapext $alignment.gapext
+          --match $alignment.match
+          --mismatch $alignment.mismatch
+          '$tracefile'
+    ]]></command>
+    <inputs>
+        <param argument="--genome" type="data" format="fasta,ab1,scf" label="FASTA, ABI or SCF format genome" />
+        <param name="tracefile" type="data" format="ab1,scf" label="Sanger chromatogram tracefile to align" />
+        <param name="index_genome" type="boolean" label="Pre-index the reference" help="Pre-indexing builds a FM index of the reference. This is required for sequences larger than 50 kilobases" />
+        <param argument="--callVariants" type="boolean" truevalue="--callVariants" falsevalue="" label="Call variants in chromatogram" />
+        <!-- annotate option is not yet supported -->
+        <expand macro="common_options" />
+        <expand macro="kmer_options" />
+        <expand macro="alignment_options" />
+        <expand macro="trim_options" />
+        <expand macro="optional_outputs" />
+    </inputs>
+    <outputs>
+        <expand macro="json_output" toolname="decompose" />
+        <data name="out_fasta1" format="fasta" from_work_dir="out.align1" label="tracy decompose allele1 on ${on_string}" />
+        <data name="out_fasta2" format="fasta" from_work_dir="out.align2" label="tracy decompose allele2 on ${on_string}" />
+        <data name="out_fasta3" format="fasta" from_work_dir="out.align3" label="tracy decompose both alleles on ${on_string}" />
+        <expand macro="tabular_output" toolname="decompose" />
+        <data name="out_bcf" format="bcf" from_work_dir="out.bcf" label="tracy decompose variants on ${on_string}">
+            <filter>callVariants</filter>
+        </data>
+    </outputs>
+    <tests>
+        <test expect_num_outputs="3">
+            <param name="genome" value="reference1.fasta" ftype="fasta" />
+            <param name="tracefile" value="input1.ab1" ftype="ab1" />
+            <output name="out_fasta1" value="out1.align1.fasta" ftype="fasta" />    
+            <output name="out_fasta2" value="out1.align2.fasta" ftype="fasta" />    
+            <output name="out_fasta3" value="out1.align3.fasta" ftype="fasta" />    
+        </test>
+        <test expect_num_outputs="4">
+            <param name="genome" value="reference1.fasta" ftype="fasta" />
+            <param name="tracefile" value="input1.ab1" ftype="ab1" />
+            <param name="callVariants" value="true" />
+            <output name="out_fasta1" value="out1.align1.fasta" ftype="fasta" />    
+            <output name="out_fasta2" value="out1.align2.fasta" ftype="fasta" />    
+            <output name="out_fasta3" value="out1.align3.fasta" ftype="fasta" />    
+            <output name="out_bcf" compare="sim_size" value="out1.bcf" ftype="bcf" />
+        </test>
+        <test expect_num_outputs="5">
+            <param name="genome" value="reference1.fasta" ftype="fasta" />
+            <param name="tracefile" value="input1.ab1" ftype="ab1" />
+            <param name="callVariants" value="true" />
+            <param name="optional_outputs" value="json" />
+            <output name="out_json" ftype="json">
+                <assert_contents>
+                    <has_text text='"peakA": [5, 5, 5, 5, 5, 4' />
+                </assert_contents>
+            </output>
+            <output name="out_fasta1" value="out1.align1.fasta" ftype="fasta" />    
+            <output name="out_fasta2" value="out1.align2.fasta" ftype="fasta" />    
+            <output name="out_fasta3" value="out1.align3.fasta" ftype="fasta" />    
+            <output name="out_bcf" compare="sim_size" value="out1.bcf" ftype="bcf" />
+        </test>
+        <test expect_num_outputs="5">
+            <param name="genome" value="reference1.fasta" ftype="fasta" />
+            <param name="tracefile" value="input1.ab1" ftype="ab1" />
+            <param name="callVariants" value="true" />
+            <param name="optional_outputs" value="tabular" />
+            <output name="out_stats" ftype="tabular">
+                <assert_contents>
+                    <has_text_matching expression="13\s1\s2\s2\s11\s2\sT\sG\sN\s5\sY" />
+                </assert_contents>
+            </output>
+            <output name="out_fasta1" value="out1.align1.fasta" ftype="fasta" />    
+            <output name="out_fasta2" value="out1.align2.fasta" ftype="fasta" />    
+            <output name="out_fasta3" value="out1.align3.fasta" ftype="fasta" />    
+            <output name="out_bcf" compare="sim_size" value="out1.bcf" ftype="bcf" />
+        </test>
+    </tests>
+    <help><![CDATA[
+**What this does**
+
+Double-peaks in a trace file can cause alignment issues. This tool uses tracy_ to decompose 
+heterozygous variants in a trace file into two separate alleles. Each allele is then aligned
+separately to the reference sequence.
+
+Optionally, variants between the trace file and the reference are also output in BCF format.
+
+@pratio@
+
+@trim_options@
+
+@alignment@
+
+Read more here_.
+
+.. _tracy: https://github.com/gear-genomics/tracy
+.. _here: https://www.gear-genomics.com/docs/tracy/cli/#deconvolution-of-heterozygous-mutations
+    ]]></help>
+    <expand macro="citations" />
+</tool>
\ No newline at end of file