annotate bamCorrelate.xml @ 15:b96676609e10 draft

Uploaded
author bgruening
date Mon, 16 Dec 2013 14:08:15 -0500
parents baf4283e2d7f
children 16310f8b24d5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
10
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
1 <tool id="deeptools_bamCorrelate" name="bamCorrelate" version="1.0.2">
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
2 <description>correlates pairs of BAM files</description>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
3 <expand macro="requirements" />
10
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
4 <expand macro="stdio" />
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
5 <macros>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
6 <import>deepTools_macros.xml</import>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
7 </macros>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
8 <command>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
9 #set files=[]
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
10 #set labels=[]
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
11
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
12 @multiple_input_bams@
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
13
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
14 bamCorrelate
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
15
5
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
16 $mode.modeOpt
3
9441b4e5d2d6 Uploaded
bgruening
parents: 1
diff changeset
17
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
18 @THREADS@
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
19
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
20 --bamfiles #echo " ".join($files)
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
21 --labels #echo " ".join($labels)
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
22 --fragmentLength $fragmentLength
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
23 --corMethod $corMethod
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
24
10
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
25 --plotFile $outFileName
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
26
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
27 #if $outputOpt.showOutputOpt == "yes"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
28 --outRawCounts '$outFileRawCounts'
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
29 --outFileCorMatrix '$outFileCorMatrix'
10
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
30 --plotFileFormat $output.outFileFormat
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
31 #else:
135f3bae5c56 Uploaded
bgruening
parents: 5
diff changeset
32 --plotFileFormat 'png'
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
33 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
34
5
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
35 #if $mode.modeOpt == "bins":
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
36 --binSize '$mode.binSize'
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
37 --numberOfSamples '$mode.numberOfSamples'
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
38 #else:
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
39 --BED $mode.region_file
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
40 #end if
c54d31467be4 Uploaded
bgruening
parents: 3
diff changeset
41
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
42 ## options available in both modes
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
43 #if $mode.advancedOpt.showAdvancedOpt == "yes":
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
44
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
45 #if str($mode.advancedOpt.region.value) != '':
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
46 --region '$mode.advancedOpt.region'
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
47 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
48
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
49 $mode.advancedOpt.doNotExtendPairedEnds
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
50 $mode.advancedOpt.ignoreDuplicates
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
51 $mode.advancedOpt.includeZeros
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
52
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
53 #if $mode.advancedOpt.minMappingQuality:
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
54 --minMappingQuality '$mode.advancedOpt.minMappingQuality'
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
55 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
56
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
57 #if $mode.advancedOpt.zMin:
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
58 --zMin $mode.advancedOpt.zMin
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
59 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
60 #if $mode.advancedOpt.zMax:
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
61 --zMax $mode.advancedOpt.zMax
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
62 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
63 --colorMap '$mode.advancedOpt.colorMap'
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
64
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
65 #end if
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
66 </command>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
67
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
68 <inputs>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
69 <expand macro="multiple_input_bams" />
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
70
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
71 <param name="fragmentLength" type="integer" value="300" min="1"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
72 label="Length of the average fragment size"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
73 help ="Reads will be extended to match this length unless they are paired-end, in which case they will be extended to match the fragment length. *NOTE*: If the BAM files contain mated and unmated paired-end reads, unmated reads will be extended to match the fragment length."/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
74
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
75 <param name="corMethod" type="select" label="Correlation method">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
76 <option value="pearson">Pearson</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
77 <option value="spearman">Spearman</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
78 </param>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
79
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
80 <conditional name="mode">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
81 <param name="modeOpt" type="select" label="Choose computation mode"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
82 help="In the bins mode, the correlation is computed based on equal length bins. In the BED file mode, as list of genomic regions in BED format has to be given. For each region in the BED file the number of overlapping reads is counted in each of the BAM files. Then the correlation is computed.">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
83 <option value="bins" selected="true">Bins</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
84 <option value="BED-file">Limit correlation to certain regions (BED file)</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
85 </param>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
86 <when value="bins">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
87 <param name="binSize" type="integer" value="10000" min="1"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
88 label="Bin size in bp"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
89 help="Length in base pairs for a window used to sample the genome."/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
90
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
91 <param name="numberOfSamples" type="integer" value="100000" min="1"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
92 label="Number of samples"
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
93 help="Number of samples taken from the genome to compute the scaling factors"/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
94 <expand macro="bamCorrelate_mode_actions" />
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
95 </when>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
96 <when value="BED-file">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
97 <param name="region_file" type="data" format="bed" label="Region file in BED format" help="Correlation is computed for the number of reads that overlap such regions."/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
98 <expand macro="bamCorrelate_mode_actions" />
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
99 </when>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
100
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
101 </conditional>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
102
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
103 <conditional name="outputOpt">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
104 <param name="showOutputOpt" type="select" label="Show additional output options" >
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
105 <option value="no" selected="true">no</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
106 <option value="yes">yes</option>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
107 </param>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
108 <when value="no" />
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
109 <when value="yes">
11
baf4283e2d7f Uploaded
bgruening
parents: 10
diff changeset
110 <expand macro="input_image_file_format"/>
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
111 <param name="saveRawCounts" type="boolean" label="Save the bin counts"/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
112 <param name="saveCorMatrix" type="boolean" label="Save the correlation matrix"/>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
113 </when>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
114 </conditional>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
115
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
116 </inputs>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
117 <outputs>
11
baf4283e2d7f Uploaded
bgruening
parents: 10
diff changeset
118 <expand macro="output_image_file_format" />
0
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
119 <data format="tabular" name="outFileRawCounts" label="${tool.name} on ${on_string}: bin counts">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
120 <filter>(outputOpt['showOutputOpt'] == 'yes' and outputOpt['saveRawCounts'] == True)</filter>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
121 </data>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
122 <data format="tabular" name="outFileCorMatrix" label="${tool.name} on ${on_string}: correlation matrix">
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
123 <filter>(outputOpt['showOutputOpt'] == 'yes' and outputOpt['saveCorMatrix'] == True)</filter>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
124 </data>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
125 </outputs>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
126 <help>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
127
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
128 **What it does**
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
129
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
130 This tool is useful to assess the overall similarity of different BAM files. A typical application
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
131 is to check the correlation between replicates or published data sets.
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
132
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
133 The tool splits the genomes into bins of given length. For each bin, the number of reads
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
134 found in each BAM file is counted and a correlation is computed for all
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
135 pairs of BAM files.
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
136
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
137
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
138 .. image:: $PATH_TO_IMAGES/QC_bamCorrelate_humanSamples.png
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
139 :alt: Heatmap of RNA Polymerase II ChIP-seq
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
140
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
141
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
142 **Output files**:
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
143
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
144 - diagnostic plot produced by bamCorrelate is a clustered heatmap displaying the values for each pair-wise correlation, see below for an example
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
145 - data matrix (optional) in case you want to plot the correlation values using a different program, e.g. R, this matrix can be used
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
146
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
147
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
148
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
149
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
150 -----
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
151
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
152 .. class:: infomark
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
153
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
154 @REFERENCES@
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
155
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
156 </help>
d957e25e18a3 Uploaded
bgruening
parents:
diff changeset
157 </tool>