Mercurial > repos > jjohnson > trinityrnaseq
comparison trinityrnaseq_norm.xml @ 2:5eb99d21ef0d
Add trinityrnaseq_norm and transcriptsToOrfs tools
author | Jim Johnson <jj@umn.edu> |
---|---|
date | Thu, 05 Sep 2013 08:08:21 -0500 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
1:a34ce2b18877 | 2:5eb99d21ef0d |
---|---|
1 <tool id="trinityrnaseq_norm" name="Trinity read normalization" version="0.0.2"> | |
2 <!-- Written by Jeremy Goecks, modified by Josh Bowden for normalization proceedure, now maintained here by bhaas --> | |
3 <description>Pre-process RNA-seq data to reduce coverage of highly covered areas</description> | |
4 <requirements> | |
5 <requirement type="package" version="2013_08_14">trinityrnaseq</requirement> | |
6 </requirements> | |
7 <command> | |
8 ## symlink input in work_dir | |
9 #if str($inputs.paired_or_single) == "paired": | |
10 ln -s $inputs.left_input left_reads && | |
11 ln -s $inputs.right_input right_reads && | |
12 #else: | |
13 ln -s $inputs.input single_reads && | |
14 #end if | |
15 \${TRINITY_HOME}/util/normalize_by_kmer_coverage.pl --JM $JM --max_cov $max_cov | |
16 ## Inputs. | |
17 #if str($inputs.paired_or_single) == "paired": | |
18 --left left_reads --right right_reads | |
19 #if $inputs.left_input.ext == 'fa': | |
20 --seqType fa | |
21 #else: | |
22 --seqType fq | |
23 #end if | |
24 $inputs.pe_reads_unordered | |
25 #if str($inputs.library_type) != "None": | |
26 --SS_lib_type $inputs.library_type | |
27 #end if | |
28 $inputs.pairs_together | |
29 $inputs.parallel_stats | |
30 #else: | |
31 --single single_reads | |
32 #if str($inputs.input.ext) == 'fa': | |
33 --seqType fa | |
34 #else: | |
35 --seqType fq | |
36 #end if | |
37 #if str($inputs.library_type) != "None": | |
38 --SS_lib_type $inputs.library_type | |
39 #end if | |
40 #end if | |
41 #if $kmer_size: | |
42 --KMER_SIZE $kmer_size | |
43 #end if | |
44 #if $max_pct_stdev: | |
45 --max_pct_stdev $max_pct_stdev | |
46 #end if | |
47 ## direct stdio to output | |
48 | tee $trinity_coverage_normalization_log && | |
49 #if str($inputs.paired_or_single) == "paired": | |
50 cp left_reads.normalized* $output_left && | |
51 cp right_reads.normalized* $output_right | |
52 #else: | |
53 cp single_reads.normalized* $output_single | |
54 #end if | |
55 </command> | |
56 <inputs> | |
57 <param name="JM" type="select" label="JM" help="Amount of memory to allocate to Jellyfish for Kmer catalog construction"> | |
58 <option value="1G">1G</option> | |
59 <option value="10G">10G</option> | |
60 <option value="20G">20G</option> | |
61 <option value="50G">50G</option> | |
62 <option value="100G">100G</option> | |
63 </param> | |
64 | |
65 <param name="max_cov" type="select" label="max_cov" help="Read coverage in terms of maximum covarge to keep"> | |
66 <option value="30">30</option> | |
67 <option value="40">40</option> | |
68 <option value="50">50</option> | |
69 <option value="60">60</option> | |
70 <option value="70">70</option> | |
71 <option value="100">100</option> | |
72 </param> | |
73 | |
74 <conditional name="inputs"> | |
75 <param name="paired_or_single" type="select" label="Paired or Single-end data?"> | |
76 <option value="paired">Paired</option> | |
77 <option value="single">Single</option> | |
78 </param> | |
79 <when value="paired"> | |
80 <param format="fasta,fastq" name="left_input" type="data" label="Left/Forward strand reads" help=""/> | |
81 <param format="fasta,fastq" name="right_input" type="data" label="Right/Reverse strand reads" help=""/> | |
82 <param name="library_type" type="select" label="Strand-specific Library Type"> | |
83 <option value="None">None</option> | |
84 <option value="FR">FR</option> | |
85 <option value="RF">RF</option> | |
86 </param> | |
87 <param name="pe_reads_unordered" type="boolean" truevalue="--PE_reads_unordered" falsevalue="" checked="false" label="set if the input paired-end reads are not identically ordered"/> | |
88 <param name="pairs_together" type="boolean" truevalue="--pairs_together" falsevalue="" checked="false" label="process paired reads by averaging stats between pairs and retaining linking info"/> | |
89 <param name="parallel_stats" type="boolean" truevalue="--PARALLEL_STATS" falsevalue="" checked="false" label="generate read stats in parallel for paired reads" help="(Figure 2X Inchworm memory requirement)"/> | |
90 </when> | |
91 <when value="single"> | |
92 <param format="fasta,fastq" name="input" type="data" label="Single-end reads" help=""/> | |
93 <param name="library_type" type="select" label="Strand-specific Library Type"> | |
94 <option value="None">None</option> | |
95 <option value="F">F</option> | |
96 <option value="R">R</option> | |
97 </param> | |
98 </when> | |
99 </conditional> | |
100 <param name="kmer_size" type="integer" value="" optional="true" label="KMER SIZE" help="default: 25"> | |
101 <validator type="in_range" message="kmer size between 3 and 200" min="3" max="200"/> | |
102 </param> | |
103 <param name="max_pct_stdev" type="integer" value="" optional="true" label="maximum pct of mean for stdev of kmer coverage across read" help="default: 100"> | |
104 <validator type="in_range" message="kmer size between 10 and 100" min="10" max="100"/> | |
105 </param> | |
106 | |
107 </inputs> | |
108 <stdio> | |
109 <exit_code range="1:" level="fatal" description="Failed" /> | |
110 <regex match="Error" | |
111 source="stdout" | |
112 level="fatal" | |
113 description="Failed" /> | |
114 </stdio> | |
115 <outputs> | |
116 <!-- I have not found a way to do condional outputs so all potential output files are specified and some will be empty --> | |
117 <data format="txt" name="trinity_coverage_normalization_log" label="${tool.name} on ${on_string}: log" /> | |
118 <data format_source="left_input" name="output_left" label="${tool.name} on ${on_string}: Normalized left reads"> | |
119 <filter>inputs['paired_or_single'] == "paired"</filter> | |
120 </data> | |
121 <data format_source="right_input" name="output_right" label="${tool.name} on ${on_string}: Normalized right reads"> | |
122 <filter>inputs['paired_or_single'] == "paired"</filter> | |
123 </data> | |
124 <data format_source="input" name="output_single" label="${tool.name} on ${on_string}: Normalized reads"> | |
125 <filter>inputs['paired_or_single'] == "single"</filter> | |
126 </data> | |
127 </outputs> | |
128 <tests> | |
129 <test> | |
130 <param name="JM" value="1G"/> | |
131 <param name="max_cov" value="30"/> | |
132 <param name="paired_or_single" value="single"/> | |
133 <param name="input" ftype="fastq" value="reads.left.fq"/> | |
134 <param name="library_type" value="None"/> | |
135 <output name="trinity_coverage_normalization_log"> | |
136 <assert_contents> | |
137 <has_text text="Normalization complete." /> | |
138 </assert_contents> | |
139 </output> | |
140 <output name="output_single"> | |
141 <assert_contents> | |
142 <has_text text="ACTGCATCCTGGAAAGAATCAATGGTGGCCGGAAAGTGTTTTTCAAATACAAGAGTGACAATGTGCCCTGTTGTTT" /> | |
143 </assert_contents> | |
144 </output> | |
145 </test> | |
146 <test> | |
147 <param name="JM" value="1G"/> | |
148 <param name="max_cov" value="30"/> | |
149 <param name="paired_or_single" value="paired"/> | |
150 <param name="left_input" ftype="fastq" value="reads.left.fq"/> | |
151 <param name="right_input" ftype="fastq" value="reads.right.fq"/> | |
152 <param name="library_type" value="None"/> | |
153 <param name="pe_reads_unordered" value="False"/> | |
154 <param name="pairs_together" value="False"/> | |
155 <param name="parallel_stats" value="False"/> | |
156 <output name="trinity_coverage_normalization_log"> | |
157 <assert_contents> | |
158 <has_text text="Normalization complete." /> | |
159 </assert_contents> | |
160 </output> | |
161 <output name="output_left"> | |
162 <assert_contents> | |
163 <has_text text="CTGGGCTGCAGCTAAGTTCTCTGCATCCTCCTTCTTGCTTGTGGCTGGGAAGAAGACAATGTTGTCGATGGTCTGG" /> | |
164 </assert_contents> | |
165 </output> | |
166 <output name="output_right"> | |
167 <assert_contents> | |
168 <has_text text="CTCAAATGGTTAATTCTCAGGCTGCAAATATTCGTTCAGGATGGAAGAACATTTTCTCAGTATTCCATCTAGCTGC" /> | |
169 </assert_contents> | |
170 </output> | |
171 </test> | |
172 </tests> | |
173 <help> | |
174 Runs script Trinity_ script util/normalize_by_kmer_coverage.pl which reduces data sizes with minimal impact on recovered transcripts when used by Trinity.pl. | |
175 | |
176 .. _Trinity: http://trinityrnaseq.sourceforge.net | |
177 </help> | |
178 </tool> |