71
|
1 <tool id="plant_tribes_gene_family_classifier" name="Classify gene sequences" version="0.4">
|
28
|
2 <description>into precomputed orthologous gene family clusters</description>
|
0
|
3 <requirements>
|
71
|
4 <requirement type="package" version="0.4">plant_tribes_gene_family_classifier</requirement>
|
0
|
5 </requirements>
|
|
6 <stdio>
|
|
7 <!-- Anything other than zero is an error -->
|
|
8 <exit_code range="1:" />
|
29
|
9 <exit_code range=":-1" />
|
|
10 <!-- In case the return code has not been set propery check stderr too -->
|
0
|
11 <regex match="Error:" />
|
|
12 <regex match="Exception:" />
|
|
13 </stdio>
|
|
14 <command>
|
|
15 <![CDATA[
|
39
|
16 #import os
|
35
|
17
|
21
|
18 #if str($options_type.options_type_selector) == 'advanced':
|
51
|
19 #set specify_super_orthogroups_cond = $options_type.specify_super_orthogroups_cond
|
|
20 #set specify_super_orthogroups = $specify_super_orthogroups_cond.specify_super_orthogroups
|
17
|
21 #set create_orthogroup_cond = $options_type.create_orthogroup_cond
|
|
22 #set create_orthogroup = $create_orthogroup_cond.create_orthogroup
|
44
|
23 #set specify_single_copy_cond = $options_type.specify_single_copy_cond
|
46
|
24 #set specify_single_copy = $specify_single_copy_cond.specify_single_copy
|
44
|
25
|
51
|
26 #if str($specify_super_orthogroups) == 'yes':
|
|
27 #set specify_super_orthos = True
|
|
28 #set super_orthogroups = $specify_super_orthogroups_cond.super_orthogroups
|
|
29 #else:
|
|
30 #set specify_super_orthos = False
|
|
31 #end if
|
|
32
|
21
|
33 #if str($create_orthogroup) == 'yes':
|
44
|
34 #set create_ortho_sequences = True
|
|
35 #set orthogroups_fasta_src_dir = $os.path.join('geneFamilyClassification_dir', 'orthogroups_fasta')
|
21
|
36 #set create_corresponding_coding_sequences_cond = $create_orthogroup_cond.create_corresponding_coding_sequences_cond
|
44
|
37
|
21
|
38 #if str($create_corresponding_coding_sequences_cond.create_corresponding_coding_sequences) == 'yes':
|
|
39 #set create_corresponding_coding_sequences = True
|
85
|
40 #set orthogroups_fasta_dest_dir = $output_ptorthocs.files_path
|
21
|
41 #else:
|
|
42 #set create_corresponding_coding_sequences = False
|
85
|
43 #set orthogroups_fasta_dest_dir = $output_ptortho.files_path
|
44
|
44 #end if
|
|
45 mkdir -p $orthogroups_fasta_dest_dir &&
|
21
|
46 #else:
|
|
47 #set create_ortho_sequences = False
|
23
|
48 #set create_corresponding_coding_sequences = False
|
21
|
49 #end if
|
52
|
50
|
|
51 #if str($specify_single_copy) == 'yes':
|
|
52 #set single_copy_orthogroup = True
|
|
53 #set single_copy_cond = $specify_single_copy_cond.single_copy_cond
|
|
54 #set single_copy = $single_copy_cond.single_copy
|
|
55 #if $create_ortho_sequences:
|
|
56 #set single_copy_fasta_src_dir = $os.path.join('geneFamilyClassification_dir', 'single_copy_fasta')
|
85
|
57 #set single_copy_fasta_dest_dir = $output_ptsco.files_path
|
52
|
58 mkdir -p $single_copy_fasta_dest_dir &&
|
|
59 #end if:
|
|
60 #else:
|
|
61 #set single_copy_orthogroup = False
|
|
62 #end if
|
|
63
|
13
|
64 #else:
|
47
|
65 #set single_copy_orthogroup = False
|
13
|
66 #set create_ortho_sequences = False
|
23
|
67 #set create_corresponding_coding_sequences = False
|
4
|
68 #end if
|
20
|
69
|
0
|
70 GeneFamilyClassifier
|
35
|
71 --proteins '$input'
|
67
|
72 --scaffold '$scaffold.fields.path'
|
0
|
73 --method $method
|
13
|
74 --classifier $save_hmmscan_log_cond.classifier
|
69
|
75 --config_dir '$scaffold.fields.path'
|
30
|
76 --num_threads \${GALAXY_SLOTS:-4}
|
20
|
77
|
0
|
78 #if str($options_type.options_type_selector) == 'advanced':
|
51
|
79 #if specify_super_orthos:
|
|
80 --super_orthogroups $super_orthogroups
|
|
81 #end if
|
47
|
82 #if $single_copy_orthogroup:
|
68
|
83 #if str($single_copy) == 'custom':
|
70
|
84 #set single_copy_custom_cond = $single_copy_cond.single_copy_custom_cond
|
|
85 #set single_copy_custom = $single_copy_custom_cond.single_copy_custom
|
|
86 #if str($single_copy_custom) == 'no':
|
72
|
87 --single_copy_custom 'default'
|
70
|
88 #else:
|
|
89 --single_copy_custom '$single_copy_custom_cond.single_copy_custom_config'
|
|
90 #end if
|
68
|
91 #else:
|
|
92 --single_copy_taxa $single_copy_cond.single_copy_taxa
|
|
93 --taxa_present $single_copy_cond.taxa_present
|
|
94 #end if
|
0
|
95 #end if
|
17
|
96 #if str($create_orthogroup) == 'yes':
|
0
|
97 --orthogroup_fasta
|
18
|
98 #if $create_corresponding_coding_sequences:
|
35
|
99 --coding_sequences '$create_corresponding_coding_sequences_cond.coding_sequences'
|
17
|
100 #end if
|
0
|
101 #end if
|
|
102 #end if
|
44
|
103 >/dev/null
|
20
|
104
|
13
|
105 #if str($save_hmmscan_log_cond.classifier) == 'hmmscan' or str($save_hmmscan_log_cond.classifier) == 'both':
|
|
106 #if str($save_hmmscan_log_cond.save_hmmscan_log) == 'yes':
|
15
|
107 && mv geneFamilyClassification_dir/hmmscan.log $hmmscan_log
|
13
|
108 #else:
|
15
|
109 && rm geneFamilyClassification_dir/hmmscan.log
|
13
|
110 #end if
|
12
|
111 #end if
|
20
|
112
|
58
|
113 #if $create_ortho_sequences:
|
62
|
114 #if $create_corresponding_coding_sequences:
|
81
|
115 #set out_file = $output_ptorthocs
|
62
|
116 #else:
|
81
|
117 #set out_file = $output_ptortho
|
18
|
118 #end if
|
82
|
119 && echo -e '<html>\n<head>\n<title>Galaxy - GeneFamilyClassifier Output</title>\n</head>\n<body>\n<p/>\n<ul>\n' > $out_file
|
85
|
120 #for $fname in $os.listdir($orthogroups_fasta_src_dir):
|
82
|
121 && echo -e '<li><a href="$fname">$fname</a></li>\n' >> $out_file
|
80
|
122 #end for
|
82
|
123 && echo -e '</ul>\n</body>\n</html>\n' >> $out_file
|
74
|
124 && mv $orthogroups_fasta_src_dir/* $orthogroups_fasta_dest_dir || true
|
4
|
125 #end if
|
20
|
126
|
47
|
127 #if $single_copy_orthogroup:
|
58
|
128 #if $create_ortho_sequences:
|
82
|
129 && echo -e '<html>\n<head>\n<title>Galaxy - GeneFamilyClassifier Output</title>\n</head>\n<body>\n<p/>\n<ul>\n' > $output_ptsco
|
85
|
130 #for $fname in $os.listdir($single_copy_fasta_src_dir):
|
82
|
131 && echo -e '<li><a href="$fname">$fname</a></li>\n' >> $output_ptsco
|
80
|
132 #end for
|
82
|
133 && echo -e '</ul>\n</body>\n</html>\n' >> $output_ptsco
|
74
|
134 && mv $single_copy_fasta_src_dir/* $single_copy_fasta_dest_dir || true
|
48
|
135 #end if
|
44
|
136 #end if
|
0
|
137 ]]>
|
|
138 </command>
|
|
139 <inputs>
|
|
140 <param name="input" format="fasta" type="data" label="Amino acids (proteins) sequences fasta file"/>
|
|
141 <param name="scaffold" type="select" label="Orthogroups or gene families proteins scaffold">
|
|
142 <options from_data_table="plant_tribes_scaffolds" />
|
39
|
143 <validator type="no_options" message="No PlantTribes scaffolds are available. Use the PlantTribes Scaffolds Download Data Manager tool in Galaxy to install and populate the PlantTribes scaffolds data table."/>
|
0
|
144 </param>
|
|
145 <param name="method" type="select" label="Protein clustering method">
|
|
146 <option value="gfam" selected="true">GFam</option>
|
|
147 <option value="orthofinder">OrthoFinder</option>
|
|
148 <option value="orthomcl">OrthoMCL</option>
|
|
149 </param>
|
13
|
150 <conditional name="save_hmmscan_log_cond">
|
|
151 <param name="classifier" type="select" label="Protein classification method">
|
|
152 <option value="blastp" selected="true">blastp</option>
|
|
153 <option value="hmmscan">HMMScan</option>
|
|
154 <option value="both">Both blastp and HMMScan</option>
|
|
155 </param>
|
|
156 <when value="blastp" />
|
|
157 <when value="hmmscan">
|
|
158 <param name="save_hmmscan_log" type="select" label="Save hmmscan log?" help="Save the hmmscan log in an additional output dataset">
|
|
159 <option value="no" selected="true">No</option>
|
|
160 <option value="yes">Yes</option>
|
|
161 </param>
|
|
162 </when>
|
|
163 <when value="both">
|
|
164 <param name="save_hmmscan_log" type="select" label="Save hmmscan log?" help="Save the hmmscan log in an additional output dataset">
|
|
165 <option value="no" selected="true">No</option>
|
|
166 <option value="yes">Yes</option>
|
|
167 </param>
|
|
168 </when>
|
|
169 </conditional>
|
0
|
170 <conditional name="options_type">
|
|
171 <param name="options_type_selector" type="select" label="Options Configuration">
|
|
172 <option value="basic" selected="true">Basic</option>
|
|
173 <option value="advanced">Advanced</option>
|
|
174 </param>
|
|
175 <when value="basic" />
|
|
176 <when value="advanced">
|
51
|
177 <conditional name="specify_super_orthogroups_cond">
|
|
178 <param name="specify_super_orthogroups" type="select" label="Specify super orthogroups?" help="Secondary MCL clusters of orthogroups">
|
|
179 <option value="no" selected="true">No</option>
|
|
180 <option value="yes">Yes</option>
|
|
181 </param>
|
|
182 <when value="no"/>
|
|
183 <when value="yes">
|
|
184 <param name="super_orthogroups" type="select" label="Super Orthogroups">
|
|
185 <option value="min_evalue" selected="true">Minimum e-value</option>
|
|
186 <option value="avg_evalue">Average e-value</option>
|
|
187 </param>
|
|
188 </when>
|
|
189 </conditional>
|
44
|
190 <conditional name="specify_single_copy_cond">
|
|
191 <param name="specify_single_copy" type="select" label="Specify single copy orthogroup selection?">
|
|
192 <option value="no" selected="true">No</option>
|
|
193 <option value="yes">Yes</option>
|
0
|
194 </param>
|
44
|
195 <when value="no"/>
|
|
196 <when value="yes">
|
|
197 <conditional name="single_copy_cond">
|
73
|
198 <param name="single_copy" type="select" label="Select single copy orthogroup configuration option">
|
68
|
199 <option value="custom" selected="true">Single copy orthogroup custom configuration</option>
|
65
|
200 <option value="taxa">Minimum single copy taxa required in orthogroup</option>
|
44
|
201 </param>
|
70
|
202 <when value="custom">
|
|
203 <conditional name="single_copy_custom_cond">
|
73
|
204 <param name="single_copy_custom" type="select" label="Select single copy orthogroup custom configuration from the current history?" help="Select No to use the default configuration">
|
70
|
205 <option value="no" selected="true">No</option>
|
|
206 <option value="yes">Yes</option>
|
|
207 </param>
|
|
208 <when value="no"/>
|
|
209 <when value="yes">
|
73
|
210 <param name="single_copy_custom_config" format="txt" type="data" label="Single copy orthogroup custom configuration file"/>
|
70
|
211 </when>
|
|
212 </conditional>
|
|
213 </when>
|
44
|
214 <when value="taxa">
|
65
|
215 <param name="single_copy_taxa" type="integer" value="20" label="Minimum single copy taxa required in orthogroup"/>
|
|
216 <param name="taxa_present" type="integer" value="21" label="Minimum taxa required in single copy orthogroup"/>
|
44
|
217 </when>
|
|
218 </conditional>
|
0
|
219 </when>
|
|
220 </conditional>
|
|
221 <conditional name="create_orthogroup_cond">
|
|
222 <param name="create_orthogroup" type="select" label="Create orthogroup fasta files?">
|
|
223 <option value="no" selected="true">No</option>
|
|
224 <option value="yes">Yes</option>
|
|
225 </param>
|
|
226 <when value="no" />
|
|
227 <when value="yes">
|
17
|
228 <conditional name="create_corresponding_coding_sequences_cond">
|
|
229 <param name="create_corresponding_coding_sequences" type="select" label="Create corresponding coding sequences?">
|
|
230 <option value="no" selected="true">No</option>
|
|
231 <option value="yes">Yes</option>
|
|
232 </param>
|
|
233 <when value="no" />
|
|
234 <when value="yes">
|
|
235 <param name="coding_sequences" format="fasta" type="data" label="Corresponding coding sequences (CDS) fasta file"/>
|
|
236 </when>
|
|
237 </conditional>
|
0
|
238 </when>
|
|
239 </conditional>
|
|
240 </when>
|
|
241 </conditional>
|
|
242 </inputs>
|
|
243 <outputs>
|
15
|
244 <data name="hmmscan_log" format="txt" label="Protein classification hmmscan.log on ${on_string}">
|
|
245 <filter>save_hmmscan_log_cond['classifier'] in ['hmmscan', 'both'] and save_hmmscan_log_cond['save_hmmscan_log'] == 'yes'</filter>
|
|
246 </data>
|
63
|
247 <data name="output_ptortho" format="ptortho" label="Gene family clusters on ${on_string}">
|
33
|
248 <filter>options_type['options_type_selector'] == 'advanced' and options_type['create_orthogroup_cond']['create_orthogroup'] == 'yes' and options_type['create_orthogroup_cond']['create_corresponding_coding_sequences_cond']['create_corresponding_coding_sequences'] == 'no'</filter>
|
31
|
249 </data>
|
63
|
250 <data name="output_ptorthocs" format="ptorthocs" label="Gene family clusters and corresponding coding sequences on ${on_string}">
|
31
|
251 <filter>options_type['options_type_selector'] == 'advanced' and options_type['create_orthogroup_cond']['create_orthogroup'] == 'yes' and options_type['create_orthogroup_cond']['create_corresponding_coding_sequences_cond']['create_corresponding_coding_sequences'] == 'yes'</filter>
|
9
|
252 </data>
|
63
|
253 <data name="output_ptsco" format="tabular" label="Single copy orthogroups on ${on_string}">
|
53
|
254 <filter>options_type['options_type_selector'] == 'advanced' and options_type['create_orthogroup_cond']['create_orthogroup'] == 'yes' and options_type['specify_single_copy_cond']['specify_single_copy'] == 'yes'</filter>
|
63
|
255 <change_format>
|
|
256 <when input="options_type.create_orthogroup_cond.create_corresponding_coding_sequences_cond.create_corresponding_coding_sequences" value="no" format="ptortho" />
|
|
257 <when input="options_type.create_orthogroup_cond.create_corresponding_coding_sequences_cond.create_corresponding_coding_sequences" value="yes" format="ptorthocs" />
|
|
258 </change_format>
|
52
|
259 </data>
|
30
|
260 <collection name="orthos" type="list">
|
12
|
261 <discover_datasets pattern="__name__" directory="geneFamilyClassification_dir" visible="false" ext="tabular" />
|
0
|
262 </collection>
|
|
263 </outputs>
|
|
264 <tests>
|
|
265 <test>
|
30
|
266 <param name="input" value="transcripts.cleaned.nr.pep" ftype="fasta" />
|
|
267 <param name="scaffold" value="22Gv1.1"/>
|
|
268 <param name="method" value="orthomcl"/>
|
|
269 <param name="classifier" value="blastp"/>
|
0
|
270 <param name="dereplicate" value="yes"/>
|
|
271 <param name="min_length" value="200"/>
|
|
272 <output_collection name="orthos" type="list">
|
35
|
273 <element name="proteins.blastp.22Gv1.1" file="proteins.blastp.22Gv1.1" ftype="tabular"/>
|
|
274 <element name="proteins.blastp.22Gv1.1.bestOrthos" file="proteins.blastp.22Gv1.1.bestOrthos" ftype="tabular"/>
|
|
275 <element name="proteins.blastp.22Gv1.1.bestOrthos.summary" file="proteins.blastp.22Gv1.1.bestOrthos.summary" ftype="tabular"/>
|
0
|
276 </output_collection>
|
|
277 </test>
|
|
278 </tests>
|
|
279 <help>
|
|
280 This tool is one of the PlantTribes' collection of automated modular analysis pipelines that utilize objective classifications of
|
28
|
281 complete protein sequences from sequenced plant genomes to perform comparative evolutionary studies. This tool classifies gene
|
|
282 sequences into precomputed orthologous gene family clusters using either blastp (faster), HMMScan (slower but more sensitive
|
|
283 to remote homologs) or both (more exhaustive).
|
|
284
|
30
|
285 This tool accepts any of the following as input:
|
28
|
286
|
|
287 * the postprocessed assemblies produced by the **Postprocess de novo assembly transcripts into putative coding sequences** tool
|
|
288 * externally predicted coding sequences and their corresponding amino acid translations derived from a transcriptome assembly
|
|
289 * gene predictions from a sequenced genome
|
0
|
290
|
|
291 -----
|
|
292
|
|
293 **Options**
|
|
294
|
67
|
295 * **Orthogroups or gene families proteins scaffold** - PlantTribes scaffolds data installed into Galaxy by the PlantTribes Scaffolds Download Data Manager tool.
|
28
|
296 * **Protein clustering method** - One of GFam (domain architecture based clustering), OrthoFinder (broadly defined clusters) or OrthoMCL (narrowly defined clusters).
|
|
297 * **Protein classification method** - blastp (faster), HMMScan (slower but more sensative to the remote homologs) or both (more exhaustive).
|
|
298 * **Super Orthogroups** - Secondary MCL clusters of orthogroups.
|
73
|
299 * **Specify single copy orthogroup selection?** - Specify a single copy orthogroup custom configuration or the minimum single copy taxa required in the orthogroup.
|
|
300 * **Select single copy orthogroup custom configuration from the current history?** - If a custom configuration is chosen, the configuration can be selected from the current history or the default configuration can be used.
|
65
|
301 * **Minimum single copy taxa required in orthogroup** - Used with "Minimum single copy taxa required in orthogroup" configuration only.
|
|
302 * **Minimum taxa required in single copy orthogroup** - Used with "Minimum single copy taxa required in orthogroup" configuration only.
|
0
|
303 * **Corresponding coding sequences (CDS) fasta file** - Used only when selecting "Create orthogroup fasta files?".
|
|
304
|
|
305 </help>
|
|
306 <citations>
|
|
307 <citation type="bibtex">
|
|
308 @unpublished{None,
|
28
|
309 author = {Eric Wafula},
|
0
|
310 title = {None},
|
|
311 year = {None},
|
35
|
312 url = {https://github.com/dePamphilis/PlantTribes}
|
|
313 }</citation>
|
|
314 <citation type="doi">10.1186/1471-2105-10-421</citation>
|
|
315 <citation type="bibtex">
|
|
316 @unpublished{None,
|
|
317 author = {None},
|
|
318 title = {HMMER 3.1+ hmmscan search sequence(s) against a profile database},
|
|
319 year = {2013},
|
|
320 url = {http://hmmer.org/}
|
0
|
321 }</citation>
|
|
322 </citations>
|
|
323 </tool>
|