26
|
1 <tool id="plant_tribes_kaks_analysis" name="KaKsAnalysis" version="@WRAPPER_VERSION@.0">
|
25
|
2 <description>estimates paralogous and orthologous pairwise synonymous (Ks) and non-synonymous (Ka) substitution rates</description>
|
26
|
3 <macros>
|
|
4 <import>macros.xml</import>
|
|
5 </macros>
|
|
6 <expand macro="requirements_kaks_analysis" />
|
32
|
7 <command detect_errors="exit_code">
|
0
|
8 <![CDATA[
|
5
|
9 #set output_dir = 'kaksAnalysis_dir'
|
4
|
10 #set comparison = $comparison_cond.comparison
|
0
|
11 #if str($options_type.options_type_selector) == 'advanced':
|
|
12 #set codeml_ctl_file_cond = $options_type.codeml_ctl_file_cond
|
|
13 #set codeml_ctl_file_select = $codeml_ctl_file_cond.codeml_ctl_file_select
|
|
14 #set fit_components_cond = $options_type.fit_components_cond
|
|
15 #set fit_components = $fit_components_cond.fit_components
|
11
|
16 #set recalibrate_cond = $options_type.recalibrate_cond
|
|
17 #set recalibrate = $recalibrate_cond.recalibrate
|
|
18 #set set_min_coverage_cond = $options_type.set_min_coverage_cond
|
|
19 #set set_min_coverage = $set_min_coverage_cond.set_min_coverage
|
17
|
20 #set set_lower_ks_limit_cond = $options_type.set_lower_ks_limit_cond
|
16
|
21 #set set_lower_ks_limit = $set_lower_ks_limit_cond.set_lower_ks_limit
|
17
|
22 #set set_upper_ks_limit_cond = $options_type.set_upper_ks_limit_cond
|
16
|
23 #set set_upper_ks_limit = $set_upper_ks_limit_cond.set_upper_ks_limit
|
6
|
24 #else:
|
|
25 #set codeml_ctl_file_select = 'no'
|
|
26 #set fit_components = 'no'
|
16
|
27 #set set_lower_ks_limit = 'no'
|
|
28 #set set_upper_ks_limit = 'no'
|
0
|
29 #end if
|
|
30 KaKsAnalysis
|
|
31 --num_threads \${GALAXY_SLOTS:-4}
|
|
32 --coding_sequences_species_1 '$coding_sequences_species_1'
|
|
33 --proteins_species_1 '$proteins_species_1'
|
|
34 --comparison $comparison
|
4
|
35 #if str($comparison) == 'orthologs':
|
0
|
36 --coding_sequences_species_2 '$comparison_cond.coding_sequences_species_2'
|
|
37 --proteins_species_2 '$comparison_cond.proteins_species_2'
|
|
38 #end if
|
|
39 #if str($options_type.options_type_selector) == 'advanced':
|
11
|
40 #if str($set_min_coverage) == 'yes':
|
|
41 --min_coverage $set_min_coverage_cond.min_coverage
|
|
42 #end if
|
|
43 #if str($recalibrate) == 'yes':
|
|
44 --recalibration_rate $recalibrate_cond.recalibration_rate
|
|
45 #end if
|
0
|
46 #if str($codeml_ctl_file_select) == 'yes':
|
|
47 --codeml_ctl_file '$codeml_ctl_file_cond.codeml_ctl_file'
|
|
48 # No else block needed here because the default codeml_ctl config
|
|
49 # will be used if the --codeml_ctl_file flag is missing.
|
|
50 #end if
|
|
51 #if str($fit_components) == 'yes':
|
10
|
52 --fit_components
|
0
|
53 --num_of_components $fit_components_cond.num_of_components
|
16
|
54 #end if
|
|
55 #if str($set_lower_ks_limit) == 'yes':
|
|
56 --min_ks $set_lower_ks_limit_cond.min_ks
|
|
57 #end if
|
|
58 #if str($set_upper_ks_limit) == 'yes':
|
|
59 --max_ks $set_upper_ks_limit_cond.max_ks
|
0
|
60 #end if
|
|
61 #end if
|
7
|
62 >/dev/null
|
5
|
63 && mv $output_dir/species1.fna '$output_species1_fna'
|
|
64 && mv $output_dir/species1.faa '$output_species1_faa'
|
9
|
65 #if str($comparison) == 'paralogs':
|
5
|
66 && mv $output_dir/species1.fna.blastn.paralogs '$output_species1_paralog'
|
9
|
67 #else:
|
5
|
68 && mv $output_dir/species2.faa '$output_species2_faa'
|
|
69 && mv $output_dir/species2.fna '$output_species2_fna'
|
|
70 && mv $output_dir/species1.fna.blastn.orthologs '$output_species1_ortholog'
|
|
71 && mv $output_dir/species2.fna.blastn.orthologs '$output_species2_ortholog'
|
|
72 #end if
|
|
73 && mv $output_dir/*.rbhb '$output_rbhb'
|
|
74 && mv $output_dir/*.kaks '$output_kaks'
|
|
75 #if str($fit_components) == 'yes':
|
|
76 && mv $output_dir/*.components '$output_components'
|
|
77 #end if
|
0
|
78 ]]>
|
|
79 </command>
|
|
80 <inputs>
|
27
|
81 <param name="coding_sequences_species_1" format="fasta" type="data" label="Coding sequences for the first species" />
|
|
82 <param name="proteins_species_1" format="fasta" type="data" label="Protein sequences for the first species" />
|
0
|
83 <conditional name="comparison_cond">
|
27
|
84 <param name="comparison" type="select" label="Type of sequence comparison">
|
|
85 <option value="paralogs" selected="true">Paralogous</option>
|
|
86 <option value="orthologs">Orthologous</option>
|
0
|
87 </param>
|
|
88 <when value="paralogs" />
|
|
89 <when value="orthologs">
|
27
|
90 <param name="coding_sequences_species_2" format="fasta" type="data" label="Coding sequences for the second species" />
|
|
91 <param name="proteins_species_2" format="fasta" type="data" label="Protein sequences for the second species" />
|
0
|
92 </when>
|
|
93 </conditional>
|
|
94 <conditional name="options_type">
|
|
95 <param name="options_type_selector" type="select" label="Options Configuration">
|
|
96 <option value="basic" selected="true">Basic</option>
|
|
97 <option value="advanced">Advanced</option>
|
|
98 </param>
|
|
99 <when value="basic" />
|
|
100 <when value="advanced">
|
11
|
101 <conditional name="set_min_coverage_cond">
|
27
|
102 <param name="set_min_coverage" type="select" label="Alignment coverage configuration">
|
11
|
103 <option value="no" selected="true">No</option>
|
|
104 <option value="yes">Yes</option>
|
|
105 </param>
|
|
106 <when value="no" />
|
|
107 <when value="yes">
|
27
|
108 <param name="min_coverage" type="float" value="0.5" min="0.3" max="1.0" label="match score" />
|
11
|
109 </when>
|
|
110 </conditional>
|
|
111 <conditional name="recalibrate_cond">
|
27
|
112 <param name="recalibrate" type="select" label="Species rates recalibration configuration">
|
11
|
113 <option value="no" selected="true">No</option>
|
|
114 <option value="yes">Yes</option>
|
|
115 </param>
|
|
116 <when value="no" />
|
|
117 <when value="yes">
|
27
|
118 <param name="recalibration_rate" type="float" value="0.0" min="0.0" label="Recalibration rate" />
|
11
|
119 </when>
|
|
120 </conditional>
|
0
|
121 <conditional name="codeml_ctl_file_cond">
|
27
|
122 <param name="codeml_ctl_file_select" type="select" label="PAML codeml configuration">
|
0
|
123 <option value="no" selected="true">No</option>
|
|
124 <option value="yes">Yes</option>
|
|
125 </param>
|
|
126 <when value="no" />
|
|
127 <when value="yes">
|
|
128 <param name="codeml_ctl_file" format="txt" type="data" label="PAML codeml control file" />
|
|
129 </when>
|
|
130 </conditional>
|
|
131 <conditional name="fit_components_cond">
|
27
|
132 <param name="fit_components" type="select" label="Rates clustering configuration">
|
0
|
133 <option value="no" selected="true">No</option>
|
|
134 <option value="yes">Yes</option>
|
|
135 </param>
|
|
136 <when value="no" />
|
|
137 <when value="yes">
|
27
|
138 <param name="num_of_components" type="integer" value="1" min="1" label="Number of components" />
|
16
|
139 </when>
|
|
140 </conditional>
|
|
141 <conditional name="set_lower_ks_limit_cond">
|
27
|
142 <param name="set_lower_ks_limit" type="select" label="Lower limit synonymous subsitution rates configuration">
|
16
|
143 <option value="no" selected="true">No</option>
|
|
144 <option value="yes">Yes</option>
|
|
145 </param>
|
|
146 <when value="no" />
|
|
147 <when value="yes">
|
27
|
148 <param name="min_ks" type="float" value="0.0" min="0.0" label="Minimum rate" />
|
16
|
149 </when>
|
|
150 </conditional>
|
|
151 <conditional name="set_upper_ks_limit_cond">
|
27
|
152 <param name="set_upper_ks_limit" type="select" label="Upper limit synonymous subsitution rates configuration">
|
16
|
153 <option value="no" selected="true">No</option>
|
|
154 <option value="yes">Yes</option>
|
|
155 </param>
|
|
156 <when value="no" />
|
|
157 <when value="yes">
|
27
|
158 <param name="max_ks" type="float" value="0.0" min="0.0" label="Maximum rate" />
|
0
|
159 </when>
|
|
160 </conditional>
|
|
161 </when>
|
|
162 </conditional>
|
15
|
163 <!-- Required due to the Emmix license -->
|
14
|
164 <param name="non_commercial_use" label="I certify that I am not using this tool for commercial purposes." type="boolean" truevalue="NON_COMMERCIAL_USE" falsevalue="COMMERCIAL_USE" checked="False">
|
|
165 <validator type="expression" message="This tool is only available for non-commercial use.">value == True</validator>
|
|
166 </param>
|
0
|
167 </inputs>
|
|
168 <outputs>
|
5
|
169 <data name="output_species1_fna" format="fasta" label="KaKs analysis (coding sequences) on ${on_string}" />
|
|
170 <data name="output_species1_faa" format="fasta" label="KaKs analysis (amino acids) on ${on_string}" />
|
|
171 <data name="output_species2_fna" format="fasta" label="KaKs analysis (coding sequences) on ${on_string}">
|
|
172 <filter>comparison_cond['comparison'] == 'orthologs'</filter>
|
|
173 </data>
|
|
174 <data name="output_species2_faa" format="fasta" label="KaKs analysis (amino acids) on ${on_string}">
|
|
175 <filter>comparison_cond['comparison'] == 'orthologs'</filter>
|
|
176 </data>
|
|
177 <data name="output_species1_paralog" format="tabular" label="KaKs analysis (blastn results) on ${on_string}">
|
|
178 <filter>comparison_cond['comparison'] == 'paralogs'</filter>
|
|
179 </data>
|
|
180 <data name="output_species1_ortholog" format="tabular" label="KaKs analysis (blastn results) on ${on_string}">
|
|
181 <filter>comparison_cond['comparison'] == 'orthologs'</filter>
|
|
182 </data>
|
|
183 <data name="output_species2_ortholog" format="tabular" label="KaKs analysis (blastn results) on ${on_string}">
|
|
184 <filter>comparison_cond['comparison'] == 'orthologs'</filter>
|
|
185 </data>
|
|
186 <data name="output_rbhb" format="tabular" label="KaKs analysis (paralogous pairs) on ${on_string}" />
|
|
187 <data name="output_kaks" format="tabular" label="KaKs analysis on ${on_string}" />
|
|
188 <data name="output_components" format="tabular" label="KaKs analysis (significant components in the ks distribution) on ${on_string}">
|
19
|
189 <filter>options_type['options_type_selector'] == 'advanced' and options_type['fit_components_cond']['fit_components'] == 'yes'</filter>
|
5
|
190 </data>
|
0
|
191 </outputs>
|
|
192 <tests>
|
|
193 <test>
|
|
194 </test>
|
|
195 </tests>
|
|
196 <help>
|
27
|
197 This tool is one of the PlantTribes collection of automated modular analysis pipelines for comparative and evolutionary analyses
|
|
198 of genome-scale gene families and transcriptomes. This tool estimates paralogous and orthologous pairwise synonymous (Ks) and
|
|
199 non-synonymous (Ka) substitution rates for a set of gene coding sequences either produced by the AssemblyPostProcessor tool or
|
|
200 from an external source. Optionally, the resulting set of estimated Ks values can be clustered into components using a mixture
|
|
201 of multivariate normal distributions to identify significant duplication event(s) in a species or a pair of species.
|
0
|
202
|
|
203 -----
|
|
204
|
|
205 **Options**
|
|
206
|
15
|
207 * **Required**
|
0
|
208
|
29
|
209 - **Coding sequences for the first species** - coding sequence fasta file for the first species either produced by the AssemblyPostProcessor tool or from an external source selected from your history.
|
|
210 - **Protein sequences for the first species** - corresponding protein sequence fasta files for the first species either produced by the AssemblyPostProcessor tool or from an external source selected from your history.
|
|
211 - **Type of sequence comparison** - pairwise sequence comparison to determine homolgous pairs. This can be either paralogous for self-species comparison or orthologous for cross-species comparison. Cross-species comparision requires input for the second species.
|
0
|
212
|
15
|
213 * **Optional**
|
0
|
214
|
29
|
215 - **Coding sequences for the second species** - coding sequence fasta file for the second species either produced by the AssemblyPostProcessor tool or from an external source selected from your history. This option is required only for orthologous comparison.
|
|
216 - **Protein sequences for the second species** - corresponding protein sequence fasta files for the second species either produced by the AssemblyPostProcessor tool or from an external source selected from your history. This option is required only for orthologous comparison.
|
27
|
217 - **Alignment coverage configuration** - select 'Yes' to set the minimum allowable alignment coverage length between homologous pairs. PlantTribes uses global codon alignment match score to determine the pairwise alignment coverage. By default, the match score is set to 0.5 if 'No' is selected.
|
|
218
|
|
219 - **match score** - number of base matches in a pairwise sequence alignment divided by the length of shorter sequence. Positions in the alignment corresponding to gaps are not considered. The score is restricted to the range 0.3 - 1.0.
|
|
220
|
31
|
221 - **Species rates recalibration configuration** - select 'Yes' to recalibrate synonymous substitution rates of a species using a predetermined evolutionary rate. Recalibration evolutionary rate can be determined from a species tree inferred from a collection of conserved single copy genes from taxa of interest as described in [7]. Rate recalibration applies only to paralogous comparisons.
|
27
|
222
|
|
223 - **recalibration rate** - a predetermined evolutionary recalibration rate.
|
|
224
|
|
225 - **PAML codeml configuration** - select 'Yes' to enable selection of a PAML codeml control file to carry out maximum likelihood analysis of protein-coding DNA sequences using codon substitution models. Template file "codeml.ctl.args" can be found in the scaffold data installed into Galaxy via the PlantTribes Scaffolds Download Data Manager tool, and are also available at the PlantTribes GitHub `repository`_. Default settings shown in the template are used if 'No' is selected.
|
|
226 - **Rates clustering configuration** - select 'Yes' to estimate clusters of synonymous substitution rates using a mixture of multivariate normal distributions which represent putative duplication event(s).
|
|
227
|
|
228 - **Number of components** - number of components to include in the normal mixture model.
|
|
229
|
|
230 - **Lower limit synonymous subsitution rates configuration** - select 'Yes' to set the minimum allowable synonymous substitution rate to use in the normal mixtures cluster analysis to exclude young paralogs that arise from normal gene births and deaths in a genome.
|
|
231
|
|
232 - **Minimum rate** - minimum allowable synonymous substitution rate.
|
|
233
|
|
234 - **Upper limit synonymous subsitution rates configuration** - select 'Yes' to set the maximum allowable synonymous substitution rate to use in the normal mixtures cluster analysis to exclude likely ancient paralogs in a genome.
|
|
235
|
28
|
236 - **Maximum rate** - maximum allowable synonymous substitution rate.
|
27
|
237
|
28
|
238 .. _repository: https://github.com/dePamphilis/PlantTribes/blob/master/config/codeml.ctl.args
|
0
|
239
|
|
240 </help>
|
|
241 <citations>
|
26
|
242 <expand macro="citation1" />
|
27
|
243 <citation type="bibtex">
|
|
244 @article{Wall2008,
|
|
245 journal = {Nucleic Acids Research},
|
|
246 author = {2. Wall PK, Leebens-Mack J, Muller KF, Field D, Altman NS},
|
|
247 title = {PlantTribes: a gene and gene family resource for comparative genomics in plants},
|
|
248 year = {2008},
|
|
249 volume = {36},
|
|
250 number = {suppl 1},
|
|
251 pages = {D970-D976},}
|
|
252 </citation>
|
|
253 <citation type="bibtex">
|
|
254 @article{Altschul1990,
|
|
255 journal = {Journal of molecular biology}
|
|
256 author = {3. Altschul SF, Gish W, Miller W, Myers EW, Lipman DJ},
|
|
257 title = {Basic local alignment search tool},
|
|
258 year = {1990},
|
|
259 volume = {215},
|
|
260 number = {3},
|
|
261 pages = {403-410},}
|
|
262 </citation>
|
|
263 <citation type="bibtex">
|
|
264 @article{Katoh2013,
|
|
265 journal = {Molecular biology and evolution},
|
|
266 author = {4. Katoh K, Standley DM},
|
|
267 title = {MAFFT multiple sequence alignment software version 7: improvements in performance and usability},
|
|
268 year = {2013},
|
|
269 volume = {30},
|
|
270 number = {4},
|
|
271 pages = {772-780},}
|
|
272 </citation>
|
|
273 <citation type="bibtex">
|
|
274 @article{Yang2007,
|
|
275 journal = {Molecular biology and evolution},
|
|
276 author = {5. Yang Z},
|
|
277 title = {PAML 4: phylogenetic analysis by maximum likelihood},
|
|
278 year = {2007},
|
|
279 volume = {24},
|
|
280 number = {8},
|
|
281 pages = {1586-1591},}
|
|
282 </citation>
|
|
283 <citation type="bibtex">
|
|
284 @article{McLachlan1999,
|
|
285 journal = {Journal of Statistical Software},
|
|
286 author = {6. McLachlan GJ, Peel D, Basford KE, Adams P},
|
|
287 title = {The EMMIX software for the fitting of mixtures of normal and t-components},
|
|
288 year = {1999},
|
|
289 volume = {4},
|
|
290 number = {2},
|
|
291 pages = {1-14},}
|
|
292 </citation>
|
31
|
293 <citation type="bibtex">
|
|
294 @article{Cui2006,
|
|
295 journal = {Genome Research},
|
|
296 author = {7. Cui L, Wall PK, Leebens-Mack JH, Lindsay BG, Soltis DE, Doyle JJ, Soltis PS, Carlson JE, Arumuganathan K, Barakat A, Albert VA},
|
|
297 title = {Widespread genome duplications throughout the history of flowering plants},
|
|
298 year = {2006},
|
|
299 volume = {16},
|
|
300 number = {6},
|
|
301 pages = {738-749},}
|
|
302 </citation>
|
0
|
303 </citations>
|
|
304 </tool>
|