comparison computeMatrix.xml @ 0:14cb57237e46 draft

planemo upload for repository https://github.com/fidelram/deepTools/tree/master/galaxy/wrapper/ commit 0a9265a12a303b54cdaa974e82e87c2ac60962ee-dirty
author bgruening
date Mon, 25 Jan 2016 20:26:32 -0500
parents
children 275ed3e83de0
comparison
equal deleted inserted replaced
-1:000000000000 0:14cb57237e46
1 <tool id="deeptools_compute_matrix" name="computeMatrix" version="@WRAPPER_VERSION@.0">
2 <description>prepares data for plotting a heatmap or a profile of given regions</description>
3 <macros>
4 <token name="@BINARY@">computeMatrix</token>
5 <import>deepTools_macros.xml</import>
6 </macros>
7 <expand macro="requirements" />
8 <command>
9 <![CDATA[
10 #import tempfile
11
12 @BINARY@
13
14 $mode.mode_select
15 --regionsFileName
16 #for $rf in $regionsFiles:
17 '$rf.regionsFile'
18 #end for
19 --scoreFileName
20 #for $bw in $scoreFileName:
21 '$bw'
22 #end for
23 --outFileName '$outFileName'
24
25 @THREADS@
26
27 #if $output.showOutputSettings == "yes"
28 #if $output.saveMatrix:
29 --outFileNameMatrix '$outFileNameMatrix'
30 #end if
31
32 #if $output.saveSortedRegions:
33 --outFileSortedRegions '$outFileSortedRegions'
34 #end if
35 #end if
36
37 #if $mode.mode_select == "reference-point":
38 --referencePoint $mode.referencePoint
39 $mode.nanAfterEnd
40 --beforeRegionStartLength $mode.beforeRegionStartLength
41 --afterRegionStartLength $mode.afterRegionStartLength
42 #else
43 --regionBodyLength $mode.regionBodyLength
44 #if $mode.regionStartLength.regionStartLength_select == "yes":
45 --beforeRegionStartLength $mode.regionStartLength.beforeRegionStartLength
46 --afterRegionStartLength $mode.regionStartLength.afterRegionStartLength
47 #end if
48 #end if
49
50 #if $advancedOpt.showAdvancedOpt == "yes":
51 --sortRegions '$advancedOpt.sortRegions'
52 --sortUsing '$advancedOpt.sortUsing'
53 --averageTypeBins '$advancedOpt.averageTypeBins'
54 $advancedOpt.skipNAs
55 $advancedOpt.skipZeros
56 --binSize $advancedOpt.binSize
57
58 #if $advancedOpt.minThreshold is not None and str($advancedOpt.minThreshold) != '':
59 --minThreshold $advancedOpt.minThreshold
60 #end if
61 #if $advancedOpt.maxThreshold is not None and str($advancedOpt.maxThreshold) != '':
62 --maxThreshold $advancedOpt.maxThreshold
63 #end if
64 #if $advancedOpt.scale is not None and str($advancedOpt.scale) != '':
65 --scale $advancedOpt.scale
66 #end if
67
68 #end if
69 ]]>
70 </command>
71 <inputs>
72
73 <repeat name="regionsFiles" title="Select regions" min="1">
74 <param name="regionsFile" format="bed" type="data" label="Regions to plot"
75 help="File, in BED format, containing the regions to plot."/>
76 </repeat>
77
78 <param name="scoreFileName" format="bigwig" type="data"
79 label="Score file" multiple="True"
80 help="You can generate a bigWig file from either a
81 bedGraph or WIG file using UCSC tools or from a BAM file using the
82 bamCoverage tool. (--scoreFileName)"/>
83
84 <conditional name="mode" >
85 <param name="mode_select" type="select"
86 label="computeMatrix has two main output options"
87 help="In the scale-regions mode, all regions in the BED file are
88 stretched or shrunk to the same length (in bases) that is indicated
89 by the user. Reference-point refers to a position within the BED
90 regions (e.g start of region). In the reference-point mode only
91 those genomic positions before (upstream) and/or after (downstream)
92 the reference point will be considered.">
93 <option value="scale-regions" selected="true">scale-regions</option>
94 <option value="reference-point">reference-point</option>
95 </param>
96
97 <when value="scale-regions" >
98 <param argument="--regionBodyLength" type="integer" value="500"
99 label="Distance in bases to which all regions are going to be fit" help=""/>
100 <conditional name="regionStartLength">
101 <param name="regionStartLength_select" type="select" label="Set distance up- and downstream of the given regions">
102 <option value="no" selected="true">no</option>
103 <option value="yes">yes</option>
104 </param>
105 <when value="no" />
106 <when value="yes">
107 <param argument="--beforeRegionStartLength" type="integer" value="1000" min="1"
108 label="Distance upstream of the region start position"
109 help="If the regions are genes, this would be the
110 distance upstream of the transcription start site."/>
111 <param argument="--afterRegionStartLength" type="integer" value="1000" min="1"
112 label="Distance downstream of the region end position"
113 help="If the regions are genes, this would be the
114 distance downstream of the transcription end site."/>
115 </when>
116 </conditional>
117 </when>
118 <when value="reference-point">
119 <param name="referencePoint" type="select" label="The reference point for the plotting">
120 <option value="TSS" selected="true">beginning of region (e.g. TSS)</option>
121 <option value="TES">end of region (e.g. TES)</option>
122 <option value="center">center of region</option>
123 </param>
124 <param name="nanAfterEnd" type="boolean" truevalue="--nanAfterEnd" falsevalue=""
125 label="Discard any values after the region end"
126 help="This is useful to visualize the region end when not using the
127 scale-regions mode and when the reference-point is set to the TSS. (--nanAfterEnd)"/>
128 <param name="beforeRegionStartLength" type="integer" value="1000" min="1"
129 label="Distance upstream of the start site of the regions defined in the region file"
130 help="If the regions are genes, this would be the distance upstream of the transcription start site. (--beforeRegionStartLength)"/>
131 <param name="afterRegionStartLength" type="integer" value="1000" min="1"
132 label="Distance downstream of the end site of the given regions"
133 help="If the regions are genes, this would be the distance downstream of the transcription end site. (--afterRegionStartLength)"/>
134 </when>
135 </conditional>
136
137 <expand macro="input_graphic_output_settings">
138 <expand macro="input_save_matrix_values" />
139 </expand>
140
141 <conditional name="advancedOpt" >
142 <param name="showAdvancedOpt" type="select" label="Show advanced options" >
143 <option value="no" selected="true">no</option>
144 <option value="yes">yes</option>
145 </param>
146 <when value="no" />
147 <when value="yes">
148 <param name="binSize" type="integer" value="50" min="1"
149 label="Length, in bases, of non-overlapping bins used for averaging the score over the regions length"
150 help="(--binSize)"/>
151
152 <expand macro="sortRegions" />
153 <expand macro="sortUsing" />
154
155 <param name="averageTypeBins" type="select"
156 label="Define the type of statistic that should be displayed."
157 help="The value is computed for each bin. (--averageTypeBins)">
158 <option value="mean" selected="true">mean</option>
159 <option value="median">median</option>
160 <option value="min">min</option>
161 <option value="max">max</option>
162 <option value="sum">sum</option>
163 <option value="std">std</option>
164 </param>
165
166 <param name="missingDataAsZero" type="boolean" truevalue="--missingDataAsZero" falsevalue="" checked="False"
167 label="Convert missing values to 0?."
168 help="If set to 'yes', missing values (NAs) are converted to 0.
169 The default is to ignore such cases, which will be
170 depicted as black areas once a heatmap is created." />
171
172 <expand macro="skipZeros" />
173 <expand macro="skipNAs" />
174
175 <param name="minThreshold" type="float" optional="True"
176 label="Minimum threshold"
177 help="Any region containing a value that is equal or less than this numeric
178 value will be skipped. This is useful to skip, for example, genes where the
179 read count is zero for any of the bins. This could be the result of
180 unmappable areas and can bias the overall results. (--minThreshold)"/>
181 <param name="maxThreshold" type="float" optional="True"
182 label="Maximum threshold"
183 help="Any region containing a value that is equal or higher that this
184 numeric value will be skipped. The max threshold is useful to skip those
185 few regions with very high read counts (e.g. major satellites) that may
186 bias the average values. (--maxThreshold)"/>
187 <param name="scale" type="float" optional="True" label="Scaling factor"
188 help="If set, all values are multiplied by this number. (--scale)"/>
189 </when>
190 </conditional>
191 </inputs>
192 <outputs>
193 <data format="deeptools_compute_matrix_archive" name="outFileName" label="${tool.name} on ${on_string}: Matrix" />
194 <expand macro="output_graphic_outputs" />
195 <expand macro="output_save_matrix_values" />
196 </outputs>
197 <!--
198 computeMatrix -S test.bw -R test2.bed -a 100 -b 100 -bs 1
199 -->
200 <tests>
201 <test>
202 <param name="regionsFile" value="computeMatrix1.bed" ftype="bed" />
203 <param name="scoreFileName" value="bamCoverage_result4.bw" ftype="bigwig" />
204 <param name="showAdvancedOpt" value="yes" />
205 <param name="mode_select" value="reference-point" />
206 <param name="binSize" value="10" />
207 <param name="sortUsing" value="sum" />
208 <param name="averageTypeBins" value="sum" />
209 <param name="skipNAs" value="False" />
210 <param name="beforeRegionStartLength" value="10" />
211 <param name="afterRegionStartLength" value="10" />
212 <output name="outFileName" file="computeMatrix_result1.gz" ftype="deeptools_compute_matrix_archive" compare="sim_size" />
213 </test>
214 <test>
215 <param name="regionsFile" value="computeMatrix2.bed" ftype="bed" />
216 <param name="scoreFileName" value="computeMatrix2.bw" ftype="bigwig" />
217 <param name="showAdvancedOpt" value="yes" />
218 <param name="mode_select" value="reference-point" />
219 <param name="binSize" value="10" />
220 <param name="beforeRegionStartLength" value="10" />
221 <param name="afterRegionStartLength" value="10" />
222 <output name="outFileName" file="computeMatrix_result2.gz" ftype="deeptools_compute_matrix_archive" compare="sim_size" />
223 </test>
224 <test>
225 <param name="regionsFile" value="computeMatrix2.bed" ftype="bed" />
226 <param name="scoreFileName" value="computeMatrix2.bw" ftype="bigwig" />
227 <param name="showAdvancedOpt" value="yes" />
228 <param name="mode_select" value="scale-regions" />
229 <param name="endLabel" value="END" />
230 <param name="regionStartLength" value="yes" />
231 <output name="outFileName" file="computeMatrix_result3.gz" ftype="deeptools_compute_matrix_archive" compare="sim_size" />
232 </test>
233 </tests>
234 <help>
235 <![CDATA[
236 **What it does**
237
238 This tool prepares an intermediate file (a gzipped table of values)
239 that contains scores associated with genomic regions and can be used
240 afterwards to plot a heatmap or profile.
241
242 Genomic regions can really be anything - genes, parts of genes, ChIP-seq
243 peaks, favorite genome regions... as long as you provide a proper file
244 in BED or INTERVAL format. If you would like to compare different groups of regions
245 (i.e. genes from chromosome 2 and 3), you can supply more than 1 BED file, one for each group.
246
247 computeMatrix can also be used to filter and sort
248 regions according to their score by making use of its advanced output options.
249
250
251 .. image:: $PATH_TO_IMAGES/flowChart_computeMatrixetc.png
252 :alt: Relationship between computeMatrix, heatmapper and profiler
253
254
255 You can find more details on the computeMatrix doc page: https://deeptools.readthedocs.org/en/master/content/tools/computeMatrix.html
256
257
258 -----
259
260 @REFERENCES@
261 ]]>
262 </help>
263 <expand macro="citations" />
264 </tool>