comparison spp_wrapper.xml @ 0:d4236b60701f draft default tip

planemo upload for repository https://github.com/eba2016/spp_tool commit 2fb169b136aea9887da7ab9fdccc442443f8efa3-dirty
author gandres
date Wed, 25 May 2016 11:52:21 -0400
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:d4236b60701f
1 <tool id="modencode_peakcalling_spp" name="SPP" version="1.13.0">
2 <description>SPP cross-correlation analysis package</description>
3 <requirements>
4 <requirement type="set_environment">SCRIPT_PATH</requirement>
5 <requirement type="package" version="1.13">spp</requirement>
6 </requirements>
7 <command>python $__tool_directory__/spp_wrapper.py $options_file $output_narrow_peak $output_region_peak $output_peakshift_file $output_rdata_file $output_plot_file $output_default_file \$SCRIPT_PATH</command>
8 <configfiles>
9 <configfile name="options_file">&lt;%
10 import simplejson
11 %&gt;
12 #set $__options ={ 'experiment_name':str($experiment_name), 'chip_file':str($major_command.input_chipseq_file1) }
13
14 #if str( $major_command.input_control_file1 ) != 'None':
15 #set $__options['input_file'] = str( $major_command.input_control_file1 )
16 #end if
17
18 ##=============================================================================
19 #if str($major_command.major_command_selector) == 'cross_correlation':
20 #set $__options['action'] = str( "cross_correlation" )
21
22 #set $__options['out'] = str( $major_command.save_peakshift_file )
23 #set $__options['savp'] = str( $major_command.save_plot_file )
24 #end if
25 ##=============================================================================
26 #if str($major_command.major_command_selector) == 'peak_calling':
27 #set $__options['action'] = str( "peak_calling" )
28 #set $__options['fdr'] = str( $major_command.fdr )
29 #set $__options['npeak'] = str( $major_command.num_peaks )
30
31 #set $__options['savr'] = str( $major_command.save_regionpeak_file )
32 #set $__options['savd'] = str( $major_command.save_rdata_file )
33 #set $__options['savn'] = str( $major_command.save_narrowpeak_file )
34 #set $__options['savp'] = str( $major_command.save_plot_file )
35 #end if
36 ##=============================================================================
37 #if str($major_command.major_command_selector) == 'idr':
38 #set $__options['action'] = str( "idr" )
39 #set $__options['npeak'] = int( $major_command.num_peaks )
40
41 #set $__options['savr'] = str( $major_command.save_regionpeak_file )
42 #set $__options['out'] = str( $major_command.save_peakshift_file )
43 #set $__options['savp'] = str( $major_command.save_plot_file )
44 #end if
45 ##=============================================================================
46 #if str($major_command.major_command_selector) == 'custom':
47 #set $__options['action'] = str( "custom" )
48 #set $__options['s'] = str( $major_command.strand_shift )
49 #set $__options['x'] = str( $major_command.excluded_strand_shift )
50 #set $__options['npeak'] = int( $major_command.num_peaks )
51 #set $__options['fdr'] = int( $major_command.fdr )
52
53 #if str($major_command.user_defined_strpeak) == '':
54 #set $__options['speak'] = str( $major_command.user_defined_strpeak )
55 #else:
56 #set $__options['speak'] = "-speak=$major_command.user_defined_strpeak"
57 #end if
58
59 #if str($major_command.filter_char) == '':
60 #set $__options['filtchr'] = str( $major_command.filter_char )
61 #else:
62 #set $__options['filtchr'] = "-filtchr=$major_command.filter_char"
63 #end if
64
65 #set $__options['out'] = str( $major_command.save_peakshift_file )
66 #set $__options['savr'] = str( $major_command.save_regionpeak_file )
67 #set $__options['savd'] = str( $major_command.save_rdata_file )
68 #set $__options['savn'] = str( $major_command.save_narrowpeak_file )
69 #set $__options['savp'] = str( $major_command.save_plot_file )
70 #end if
71
72 ${ simplejson.dumps( __options ) }
73 </configfile>
74 </configfiles>
75
76 <inputs>
77 <!--experiment name and inputs-->
78 <param name="experiment_name" type="text" value="SPP in Galaxy" size="50" label="Experiment Name"/>
79
80 <!--select function to perform-->
81 <conditional name="major_command">
82 <param name="major_command_selector" type="select" label="Select action to be performed">
83 <option value="cross_correlation">Determine strand cross-correlation peak</option>
84 <option value="peak_calling">Peak calling</option>
85 <option value="idr">IDR analysis</option>
86 <option value="custom">Custom settings</option>
87 </param>
88 <when value="cross_correlation">
89 <!--cross correlation options-->
90 <param name="input_chipseq_file1" type="data" format="bam" label="ChIP-Seq Tag File" />
91 <param name="input_control_file1" type="data" format="bam" optional="True" label="ChIP-Seq Control File" />
92
93
94 <param name="save_peakshift_file" truevalue="-out=peakshift.txt" falsevalue="" type="boolean" checked="True" label="Save peakshift file" help="(-out)"/>
95 <param name="save_plot_file" truevalue="-savp" falsevalue="" type="boolean" checked="True" label="Save plot file" help="(-savp)"/>
96 </when>
97 <when value="peak_calling">
98 <!--peak calling options-->
99 <param name="input_chipseq_file1" type="data" format="bam" label="ChIP-Seq Tag File" />
100 <param name="input_control_file1" type="data" format="bam" label="ChIP-Seq Control File" />
101
102 <param name="fdr" type="text" label="False discovery rate threshold" value="0" help="default=0 (-fdr)"/>
103 <param name="num_peaks" type="text" label="Threshold on number of peaks to call" value="0" help="default=0 (-npeak)"/>
104
105 <param name="save_regionpeak_file" truevalue="-savr" falsevalue="" type="boolean" checked="True" label="Save regionpeak file " help="(-savr)"/>
106 <param name="save_rdata_file" truevalue="-savd" falsevalue="" type="boolean" checked="True" label="Save Rdata file" help="(-savd)"/>
107 <param name="save_narrowpeak_file" truevalue="-savn" falsevalue="" type="boolean" checked="True" label="Save narrowpeak file" help="(-savn)"/>
108 <param name="save_plot_file" truevalue="-savp" falsevalue="" type="boolean" checked="True" label="Save plot file" help="(-savp)"/>
109 </when>
110 <when value="idr">
111 <!--idr options-->
112 <param name="input_chipseq_file1" type="data" format="bam" label="ChIP-Seq Tag File" />
113 <param name="input_control_file1" type="data" format="bam" label="ChIP-Seq Control File" />
114
115 <param name="num_peaks" type="integer" label="Threshold on number of peaks to call" value="300000" help="default=300000 (-npeak)"/>
116
117 <param name="save_regionpeak_file" truevalue="-savr" falsevalue="" type="boolean" checked="True" label="Save regionpeak file" help="(-savr)"/>
118 <param name="save_peakshift_file" truevalue="-out=peakshift.txt" falsevalue="" type="boolean" checked="True" label="Save peakshift file" help="(-out)"/>
119 <param name="save_plot_file" truevalue="-savp" falsevalue="" type="boolean" checked="True" label="Save plot file" help="(-savp)"/>
120 </when>
121 <when value="custom">
122 <!--custom settings, includes all relevant options here-->
123 <param name="input_chipseq_file1" type="data" format="bam" label="ChIP-Seq Tag File" />
124 <param name="input_control_file1" type="data" format="bam" optional="True" label="ChIP-Seq Control File" />
125
126 <param name="strand_shift" type="text" label="Strand shifts at which cross-correlation is evaluated" size="30" value="-100:5:600" help="default=-100:5:600 (-s)"/>
127 <param name="excluded_strand_shift" type="text" label="Strand shifts to exclude" value="10:10" help="default=10:(readlen+10) (-x)"/>
128 <param name="user_defined_strpeak" type="text" label="User defined cross-correlation peak strand shift" help="(-speak)"/>
129 <param name="num_peaks" type="integer" label="Threshold on number of peaks to call" value="0" help="default=0 (-npeak)"/>
130 <param name="fdr" type="integer" label="False discovery rate threshold" value="0" help="default=0 (-fdr)"/>
131 <param name="filter_char" type="text" label="Pattern to use to remove tags that map to specific chromosomes" help="(-filtchr)"/>
132
133 <param name="save_regionpeak_file" truevalue="-savr" falsevalue="" type="boolean" checked="False" label="Save regionpeak file" help="(-savr)"/>
134 <param name="save_peakshift_file" truevalue="-out=peakshift.txt" falsevalue="" type="boolean" checked="False" label="Save peakshift file" help="(-out)"/>
135 <param name="save_rdata_file" truevalue="-savd" falsevalue="" type="boolean" checked="False" label="Save Rdata file" help="(-savd)"/>
136 <param name="save_narrowpeak_file" truevalue="-savn" falsevalue="" type="boolean" checked="False" label="Save narrowpeak file" help="(-savn)"/>
137 <param name="save_plot_file" truevalue="-savp" falsevalue="" type="boolean" checked="False" label="Save plot file" help="(-savp)"/>
138 </when>
139 </conditional>
140 </inputs>
141
142 <outputs>
143 <data name="output_default_file" format="txt" label="${tool.name}-${major_command.major_command_selector} on ${on_string}"/>
144 <data name="output_narrow_peak" format="txt" label="${tool.name}-${major_command.major_command_selector} on ${on_string} (narrowpeaks)">
145 <filter>major_command['save_narrowpeak_file'] is True</filter>
146 <filter>major_command['major_command_selector'] == 'peak_calling' or major_command['major_command_selector'] == 'custom'</filter>
147 </data>
148 <data name="output_plot_file" format="pdf" label="${tool.name}-${major_command.major_command_selector} on ${on_string} (plot)">
149 <filter>major_command['save_plot_file'] is True</filter>
150 </data>
151 <data name="output_region_peak" format="txt" label="${tool.name}-${major_command.major_command_selector} on ${on_string} (regionpeaks)">
152 <filter>major_command['save_regionpeak_file'] is True</filter>
153 <filter>major_command['major_command_selector'] == 'peak_calling' or major_command['major_command_selector'] == 'custom' or major_command['major_command_selector'] == 'idr' </filter>
154 </data>
155 <data name="output_peakshift_file" format="txt" label="${tool.name}-${major_command.major_command_selector} on ${on_string} (peakshift/phantompeak)">
156 <filter>major_command['save_peakshift_file'] is True</filter>
157 <filter>major_command['major_command_selector'] == 'cross_correlation' or major_command['major_command_selector'] == 'custom' or major_command['major_command_selector'] == 'idr' </filter>
158 </data>
159 <data name="output_rdata_file" format="txt" label="${tool.name}-${major_command.major_command_selector} on ${on_string} (Rdata)">
160 <filter>major_command['save_rdata_file'] is True</filter>
161 <filter>major_command['major_command_selector'] == 'peak_calling' or major_command['major_command_selector'] == 'custom' </filter>
162 </data>
163 </outputs>
164
165 <tests>
166 <!--none yet for spp-->
167 <test>
168 <param name="major_command_selector" value="cross_correlation"/>
169 <param name="input_chipseq_file1" value="tag_file.bam"/>
170 <param name="input_control_file1" value="control_file.bam"/>
171 <output name="output_peakshift_file">
172 <assert_contents>
173 <has_line_matching expression="^.*\t192996\t100\t0.552186886771392\t45\t0.4766414\t600\t0.1428672\t3.865035\t1.226337\t1$" />
174 <has_n_columns n="11" />
175 </assert_contents>
176 </output>
177 <output name="output_default_file">
178 <assert_contents>
179 <has_line line="done. read 192996 fragments" />
180 <has_line line="ChIP data read length 37 " />
181 <has_line line="Minimum cross-correlation value 0.1428672 " />
182 <has_line line="Peak cross-correlation value 0.552186886771392 " />
183 <has_line line="Peak strand shift 100 " />
184 <has_line line="Window half size 260 " />
185 <has_line line="Phantom peak location 45 " />
186 <has_line line="Phantom peak Correlation 0.4766414 " />
187 <has_line line="Normalized cross-correlation coefficient (NCCC) 3.865035 " />
188 <has_line line="Relative Cross correlation Coefficient (RCCC) 1.226337 " />
189 <has_line line="Phantom Peak Quality Tag 1 " />
190 </assert_contents>
191 </output>
192 </test>
193 <test>
194 <param name="major_command_selector" value="cross_correlation"/>
195 <param name="input_chipseq_file1" value="tag_file.bam"/>
196 <output name="output_peakshift_file">
197 <assert_contents>
198 <has_line_matching expression="^.*\t192996\t100\t0.552186886771392\t45\t0.4766414\t600\t0.1428672\t3.865035\t1.226337\t1$" />
199 <has_n_columns n="11" />
200 </assert_contents>
201 </output>
202 </test>
203 </tests>
204 <help>
205 **What it does**
206
207 This tool allows ChIP-seq peak calling using SPP
208
209 This set of programs operate on mapped Illumina single-end read datasets in tagAlign or BAM format.
210
211 View the modified SPP documentation: http://code.google.com/p/phantompeakqualtools/
212
213 ------
214
215 **Usage**
216
217 **Determine strand cross-correlation peak**: Compute the predominant insert-size (fragment length) based on strand cross-correlation peak.
218
219 **Peak calling**: Call Peaks and regions for punctate binding datasets.
220
221 **IDR analysis**: Compute Data quality measures based on relative phantom peak.
222
223 **Custom settings**: Enables all options available to SPP for custom analysis.
224
225 ------
226
227 **Output**
228
229
230 The column names of narrow- and region-peaks datasets (produced by **Peak calling**) are provided below:
231
232 - col 1: chrom
233 - col 2: start
234 - col 3: end
235 - col 4: name
236 - col 5: score
237 - col 6: strand
238 - col 7: signalValue
239 - col 8 : -1
240 - col 9: -log10(fdr)
241 - col 10: Point-source called for this peak.
242
243 ------
244
245
246 **Citation**
247
248 Anshul Kundaje, Computer Science Dept., Stanford University, ENCODE Consortium, Personal Communication, Oct 2010
249 Kharchenko PK, Tolstorukov MY, Park PJ, Design and analysis of ChIP-seq experiments for DNA-binding proteins Nat Biotechnol. 2008 Dec;26(12):1351-9
250
251 Integration of SPP with Galaxy performed by Ziru Zhou ( ziruzhou@gmail.com ). Please send your comments/questions to help@modencode.org.
252 </help>
253 <citations>
254 <citation type="doi">doi:10.1038/nbt.1508</citation>
255 </citations>
256 </tool>