comparison cwpair2.xml @ 0:507521bf124a draft

Uploaded
author greg
date Tue, 17 Nov 2015 14:06:28 -0500
parents
children 9ed566138ecb
comparison
equal deleted inserted replaced
-1:000000000000 0:507521bf124a
1 <?xml version="1.0"?>
2 <tool id="cwpair2" name="CWPair2" version="@WRAPPER_VERSION@.0">
3 <description>find matched pairs and unmatched orphans</description>
4 <macros>
5 <import>cwpair2_macros.xml</import>
6 </macros>
7 <expand macro="requirements" />
8 <command>
9 <![CDATA[
10 python $__tool_directory__/cwpair2.py
11 #for $i in $input:
12 --input "${i}" "${i.hid}"
13 #end for
14 --method $method
15 --up_distance $up_distance
16 --down_distance $down_distance
17 --binsize $binsize
18 --threshold_format $threshold_format_cond.threshold_format
19 #if str($threshold_format_cond.threshold_format) == "absolute_threshold":
20 --absolute_threshold $threshold_format_cond.absolute_threshold
21 #elif str($threshold_format_cond.threshold_format) == "relative_threshold":
22 --relative_threshold $threshold_format_cond.relative_threshold
23 #end if
24 --output_files $output_files_cond.output_files
25 #if str($output_files_cond.output_files) == "all"
26 --plot_format $output_files_cond.plot_format
27 #end if
28 --sort_chromosome $sort_chromosome
29 --sort_score $sort_score
30 --statistics_output "$statistics_output"
31 ]]>
32 </command>
33 <inputs>
34 <param name="input" type="data" format="gff" multiple="True" label="Find matched pairs on" />
35 <param name="method" type="select" label="Method of finding a match">
36 <option value="mode" selected="True">Mode</option>
37 <option value="closest">Closest</option>
38 <option value="largest">Largest</option>
39 <option value="all">All</option>
40 </param>
41 <param name="up_distance" type="integer" value="50" min="0" label="Distance upstream from a peak to allow a pair" />
42 <param name="down_distance" type="integer" value="100" min="0" label="Distance downstream from a peak to allow a pair" />
43 <param name="binsize" type="integer" value="1" min="0" label="Width of bins for frequency plots and mode calculation" help="Value 1 implies no bins" />
44 <conditional name="threshold_format_cond">
45 <param name="threshold_format" type="select" label="Filter using">
46 <option value="relative_threshold" selected="True">Relative threshold</option>
47 <option value="absolute_threshold">Absolute threshold</option>
48 </param>
49 <when value="relative_threshold">
50 <param name="relative_threshold" type="float" value="0.0" min="0.0" label="Percentage of the 95 percentile value to filter below" help="Value 0 results in no filtering" />
51 </when>
52 <when value="absolute_threshold">
53 <param name="absolute_threshold" type="float" value="0.0" min="0.0" label="Absolute value to filter below" />
54 </when>
55 </conditional>
56 <conditional name="output_files_cond">
57 <param name="output_files" type="select" label="Restrict output to" help="Statistics will always be generated." >
58 <option value="simple" selected="True">matched pairs only (S)</option>
59 <option value="simple_orphan">matched pairs and orphans only (O,S)</option>
60 <option value="simple_orphan_detail">matched pairs, orphans and details only (D,O,S)</option>
61 <option value="all">no restrictions (output everything: C,D,F,O,P,S)</option>
62 </param>
63 <when value="simple" />
64 <when value="simple_orphan" />
65 <when value="simple_orphan_detail" />
66 <when value="all">
67 <param name="plot_format" type="select" label="Output format for graph">
68 <option value="pdf" selected="True">Pdf</option>
69 <option value="png">Png</option>
70 <option value="svg">Svg</option>
71 </param>
72 </when>
73 </conditional>
74 <param name="sort_chromosome" type="select" label="Sort output by chromosomes in" help="Chromosome strings that are not numeric will not be sorted" >
75 <option value="asc" selected="True">ascending order</option>
76 <option value="desc">descending order</option>
77 </param>
78 <param name="sort_score" type="select" label="Sort output by score?">
79 <option value="no" selected="True">No</option>
80 <option value="asc">Yes, in ascending order</option>
81 <option value="desc">Yes, in descending order</option>
82 </param>
83 </inputs>
84 <outputs>
85 <collection name="closest_C_pdf" type="list" label="closest C: ${tool.name} on ${on_string}">
86 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "closest"]</filter>
87 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_C" ext="pdf" visible="false" />
88 </collection>
89 <collection name="closest_C_png" type="list" label="closest C: ${tool.name} on ${on_string}">
90 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "closest"]</filter>
91 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_C" ext="png" visible="false" />
92 </collection>
93 <collection name="closest_C_svg" type="list" label="closest C: ${tool.name} on ${on_string}">
94 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "closest"]</filter>
95 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_C" ext="svg" visible="false" />
96 </collection>
97 <collection name="largest_C_pdf" type="list" label="largest C: ${tool.name} on ${on_string}">
98 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "largest"]</filter>
99 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_C" ext="pdf" visible="false" />
100 </collection>
101 <collection name="largest_C_png" type="list" label="largest C: ${tool.name} on ${on_string}">
102 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "largest"]</filter>
103 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_C" ext="png" visible="false" />
104 </collection>
105 <collection name="largest_C_svg" type="list" label="largest C: ${tool.name} on ${on_string}">
106 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "largest"]</filter>
107 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_C" ext="svg" visible="false" />
108 </collection>
109 <collection name="mode_C_pdf" type="list" label="mode C: ${tool.name} on ${on_string}">
110 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "mode"]</filter>
111 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_C" ext="pdf" visible="false" />
112 </collection>
113 <collection name="mode_C_png" type="list" label="mode C: ${tool.name} on ${on_string}">
114 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "mode"]</filter>
115 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_C" ext="png" visible="false" />
116 </collection>
117 <collection name="mode_C_svg" type="list" label="mode C: ${tool.name} on ${on_string}">
118 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "mode"]</filter>
119 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_C" ext="svg" visible="false" />
120 </collection>
121 <collection name="closest_D" type="list" label="closest D: ${tool.name} on ${on_string}">
122 <filter>output_files_cond["output_files"] in ["all", "simple_orphan_detail"] and method in ["all", "closest"]</filter>
123 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_D" ext="tabular" visible="false" />
124 </collection>
125 <collection name="largest_D" type="list" label="largest D: ${tool.name} on ${on_string}">
126 <filter>output_files_cond["output_files"] in ["all", "simple_orphan_detail"] and method in ["all", "largest"]</filter>
127 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_D" ext="tabular" visible="false" />
128 </collection>
129 <collection name="mode_D" type="list" label="mode D: ${tool.name} on ${on_string}">
130 <filter>output_files_cond["output_files"] in ["all", "simple_orphan_detail"] and method in ["all", "mode"]</filter>
131 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_D" ext="tabular" visible="false" />
132 </collection>
133 <collection name="closest_F_pdf" type="list" label="closest F: ${tool.name} on ${on_string}">
134 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "closest"]</filter>
135 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_F" ext="pdf" visible="false" />
136 </collection>
137 <collection name="closest_F_png" type="list" label="closest F: ${tool.name} on ${on_string}">
138 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "closest"]</filter>
139 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_F" ext="png" visible="false" />
140 </collection>
141 <collection name="closest_F_svg" type="list" label="closest F: ${tool.name} on ${on_string}">
142 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "closest"]</filter>
143 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_F" ext="svg" visible="false" />
144 </collection>
145 <collection name="largest_F_pdf" type="list" label="largest F: ${tool.name} on ${on_string}">
146 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "largest"]</filter>
147 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_F" ext="pdf" visible="false" />
148 </collection>
149 <collection name="largest_F_png" type="list" label="largest F: ${tool.name} on ${on_string}">
150 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "largest"]</filter>
151 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_F" ext="png" visible="false" />
152 </collection>
153 <collection name="largest_F_svg" type="list" label="largest F: ${tool.name} on ${on_string}">
154 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "largest"]</filter>
155 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_F" ext="svg" visible="false" />
156 </collection>
157 <collection name="mode_F_pdf" type="list" label="mode F: ${tool.name} on ${on_string}">
158 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "mode"]</filter>
159 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_F" ext="pdf" visible="false" />
160 </collection>
161 <collection name="mode_F_png" type="list" label="mode F: ${tool.name} on ${on_string}">
162 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "mode"]</filter>
163 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_F" ext="png" visible="false" />
164 </collection>
165 <collection name="mode_F_svg" type="list" label="mode F: ${tool.name} on ${on_string}">
166 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "mode"]</filter>
167 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_F" ext="svg" visible="false" />
168 </collection>
169 <collection name="closest_O" type="list" label="closest O: ${tool.name} on ${on_string}">
170 <filter>output_files_cond["output_files"] in ["all", "simple_orphan", "simple_orphan_detail"] and method in ["all", "closest"]</filter>
171 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_O" ext="tabular" visible="false" />
172 </collection>
173 <collection name="largest_O" type="list" label="largest O: ${tool.name} on ${on_string}">
174 <filter>output_files_cond["output_files"] in ["all", "simple_orphan", "simple_orphan_detail"] and method in ["all", "largest"]</filter>
175 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_O" ext="tabular" visible="false" />
176 </collection>
177 <collection name="mode_O" type="list" label="mode O: ${tool.name} on ${on_string}">
178 <filter>output_files_cond["output_files"] in ["all", "simple_orphan", "simple_orphan_detail"] and method in ["all", "mode"]</filter>
179 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_O" ext="tabular" visible="false" />
180 </collection>
181 <collection name="closest_P_pdf" type="list" label="closest P: ${tool.name} on ${on_string}">
182 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "closest"]</filter>
183 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_P" ext="pdf" visible="false" />
184 </collection>
185 <collection name="closest_P_png" type="list" label="closest P: ${tool.name} on ${on_string}">
186 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "closest"]</filter>
187 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_P" ext="png" visible="false" />
188 </collection>
189 <collection name="closest_P_svg" type="list" label="closest P: ${tool.name} on ${on_string}">
190 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "closest"]</filter>
191 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_P" ext="svg" visible="false" />
192 </collection>
193 <collection name="largest_P_pdf" type="list" label="largest P: ${tool.name} on ${on_string}">
194 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "largest"]</filter>
195 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_P" ext="pdf" visible="false" />
196 </collection>
197 <collection name="largest_P_png" type="list" label="largest P: ${tool.name} on ${on_string}">
198 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "largest"]</filter>
199 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_P" ext="png" visible="false" />
200 </collection>
201 <collection name="largest_P_svg" type="list" label="largest P: ${tool.name} on ${on_string}">
202 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "largest"]</filter>
203 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_P" ext="svg" visible="false" />
204 </collection>
205 <collection name="mode_P_pdf" type="list" label="mode P: ${tool.name} on ${on_string}">
206 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "pdf" and method in ["all", "mode"]</filter>
207 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_P" ext="pdf" visible="false" />
208 </collection>
209 <collection name="mode_P_png" type="list" label="mode P: ${tool.name} on ${on_string}">
210 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "png" and method in ["all", "mode"]</filter>
211 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_P" ext="png" visible="false" />
212 </collection>
213 <collection name="mode_P_svg" type="list" label="mode P: ${tool.name} on ${on_string}">
214 <filter>output_files_cond["output_files"] == "all" and output_files_cond['plot_format'] == "svg" and method in ["all", "mode"]</filter>
215 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_P" ext="svg" visible="false" />
216 </collection>
217 <collection name="closest_S" type="list" label="closest S: ${tool.name} on ${on_string}">
218 <filter>method in ["all", "closest"]</filter>
219 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="closest_S" ext="gff" visible="false" />
220 </collection>
221 <collection name="largest_S" type="list" label="largest S: ${tool.name} on ${on_string}">
222 <filter>method in ["all", "largest"]</filter>
223 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="largest_S" ext="gff" visible="false" />
224 </collection>
225 <collection name="mode_S" type="list" label="mode S: ${tool.name} on ${on_string}">
226 <filter>method in ["all", "mode"]</filter>
227 <discover_datasets pattern="(?P&lt;designation&gt;.*)" directory="mode_S" ext="gff" visible="false" />
228 </collection>
229 <data name="statistics_output" format="tabular" label="Statistics: ${tool.name} on ${on_string}" />
230 </outputs>
231 <tests>
232 <test>
233 <param name="input" value="cwpair2_input1.gff" />
234 <param name="method" value="all" />
235 <param name="up_distance" value="25" />
236 <param name="down_distance" value="100" />
237 <param name="binsize" value="1" />
238 <param name="threshold_format" value="relative_threshold" />
239 <param name="relative_threshold" value="0.0" />
240 <param name="output_files" value="simple" />
241 <param name="sort_chromosome" value="asc" />
242 <param name="sort_score" value="asc" />
243 <output_collection name="closest_S" type="list">
244 <element name="closest_S_data_1_f0u25d100b1" file="closest_s_output1.gff" ftype="gff" />
245 </output_collection>
246 <output_collection name="largest_S" type="list">
247 <element name="largest_S_data_1_f0u25d100b1" file="largest_s_output1.gff" ftype="gff" />
248 </output_collection>
249 <output_collection name="mode_S" type="list">
250 <element name="mode_S_data_1_f0u25d100b1" file="mode_s_output1.gff" ftype="gff" />
251 </output_collection>
252 <output name="statistics_output" file="statistics1.tabular" ftype="tabular" />
253 </test>
254 <test>
255 <param name="input" value="cwpair2_input1.gff" />
256 <param name="method" value="all" />
257 <param name="up_distance" value="50" />
258 <param name="down_distance" value="100" />
259 <param name="binsize" value="1" />
260 <param name="threshold_format" value="relative_threshold" />
261 <param name="relative_threshold" value="0.0" />
262 <param name="output_files" value="all" />
263 <param name="plot_format" value="pdf" />
264 <param name="sort_chromosome" value="asc" />
265 <param name="sort_score" value="no" />
266 <output_collection name="closest_D" type="list">
267 <element name="closest_D_data_1_f0u50d100b1" file="closest_d_output2.tabular" ftype="tabular" />
268 </output_collection>
269 <output_collection name="closest_F" type="list">
270 <element name="closest_F_data_1_f0u50d100b1" file="closest_f_output2.pdf" ftype="pdf" compare="sim_size" />
271 </output_collection>
272 <output_collection name="closest_O" type="list">
273 <element name="closest_O_data_1_f0u50d100b1" file="closest_o_output2.tabular" ftype="tabular" />
274 </output_collection>
275 <output_collection name="closest_S" type="list">
276 <element name="closest_S_data_1_f0u50d100b1" file="closest_s_output2.gff" ftype="gff" />
277 </output_collection>
278 <output_collection name="largest_D" type="list">
279 <element name="largest_D_data_1_f0u50d100b1" file="largest_d_output2.tabular" ftype="tabular" />
280 </output_collection>
281 <output_collection name="largest_F" type="list">
282 <element name="largest_F_data_1_f0u50d100b1" file="largest_f_output2.pdf" ftype="pdf" compare="sim_size" />
283 </output_collection>
284 <output_collection name="largest_O" type="list">
285 <element name="largest_O_data_1_f0u50d100b1" file="largest_o_output2.tabular" ftype="tabular" />
286 </output_collection>
287 <output_collection name="largest_S" type="list">
288 <element name="largest_S_data_1_f0u50d100b1" file="largest_s_output2.gff" ftype="gff" />
289 </output_collection>
290 <output_collection name="mode_C" type="list">
291 <element name="mode_C_data_1_f0u50d100b1" file="mode_c_output2.pdf" ftype="pdf" compare="sim_size" />
292 </output_collection>
293 <output_collection name="mode_D" type="list">
294 <element name="mode_D_data_1_f0u50d100b1" file="mode_d_output2.tabular" ftype="tabular" />
295 </output_collection>
296 <output_collection name="mode_F" type="list">
297 <element name="mode_F_data_1_f0u50d100b1" file="mode_f_output2.pdf" ftype="pdf" compare="sim_size" />
298 </output_collection>
299 <output_collection name="mode_O" type="list">
300 <element name="mode_O_data_1_f0u50d100b1" file="mode_o_output2.tabular" ftype="tabular" />
301 </output_collection>
302 <output_collection name="mode_P" type="list">
303 <element name="mode_P_data_1_f0u50d100b1" file="mode_p_output2.pdf" ftype="pdf" compare="sim_size" />
304 </output_collection>
305 <output_collection name="mode_S" type="list">
306 <element name="mode_S_data_1_f0u50d100b1" file="mode_s_output2.gff" ftype="gff" />
307 </output_collection>
308 <output name="statistics_output" file="statistics2.tabular" ftype="tabular" />
309 </test>
310 </tests>
311 <help>
312 **What it does**
313
314 Takes a list of called peaks on both strands and produces a list of matched pairs and a list of unmatched orphans
315 using a specified method for finding matched pairs. Methods for finding matched pairs are mode, closest, largest
316 or all (where the analysis is run for each method). A statistics dataset is generated and a collection of datasets
317 is produced for each method as follows.
318
319 * **closest/largest/mode C** - the stastics graph in a specified format: pdf, png or svg
320 * **closest/largest/mode D** - the details in tabular format
321 * **closest/largest/mode F** - the final plots graph in a specified format: pdf, png or svg
322 * **closest/largest/mode O** - the orphans in tabular format
323 * **closest/largest/mode P** - the preview plots graph in a specified format: pdf, png or svg
324 * **closest/largest/mode S** - the matched pairs in gff format
325
326
327 **Options**
328
329 * **Output files** - Restrict output dataset collections to matched pairs only or one of several combinations of collection types.
330 * **Method of finding match** - Method of finding matched pair, mode, closest, largest, or all (run with each method).
331 * **Distance upstream from a peak to allow a pair** - Distance upstream from a Watson peak to allow a Crick pair.
332 * **Distance downstream from a peak to allow a pair** - Distance downstream from a Watson peak to allow a Crick pair.
333 * **Percentage of the 95 percentile value to filter below** - Percentage of the 95 percentile value below which to filter when using a relative threshold.
334 * **Absolute value to filter below** - Absolute value below which to filter when using an absolute threshold.
335 * **Output format for graph** - Output format for graph.
336 * **Sort output by chromosomes in** - Output will be sorted by chromsome in the specified order.
337 * **Sort output by score?** - If yes, output will be sorted by score in the specified order.
338 * **Summary output format** - Format for summary output.
339
340 </help>
341 <expand macro="citations" />
342 </tool>