comparison featurecounts.xml @ 30:a56fbe2d6ba7 draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/featurecounts commit 2d5d24cbdea47adb6eede757016c717840749fd1
author iuc
date Fri, 24 Feb 2023 14:02:04 +0000
parents 38b6d12edc68
children 6f66ae7c5f7a
comparison
equal deleted inserted replaced
29:38b6d12edc68 30:a56fbe2d6ba7
1 <tool id="featurecounts" name="featureCounts" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.05"> 1 <tool id="featurecounts" name="featureCounts" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.09">
2 <description>Measure gene expression in RNA-Seq experiments from SAM or BAM files</description> 2 <description>Measure gene expression in RNA-Seq experiments from SAM or BAM files</description>
3 <macros> 3 <macros>
4 <token name="@TOOL_VERSION@">2.0.1</token> 4 <token name="@TOOL_VERSION@">2.0.3</token>
5 <token name="@VERSION_SUFFIX@">2</token> 5 <token name="@VERSION_SUFFIX@">0</token>
6
7 <macro name="conditional_gff_opions">
8 <param name="gff_feature_type" type="text" value="exon" argument="-t" label="GFF feature type filter" help="Specify the feature type. Only rows which have the matched matched feature type in the provided GTF annotation file will be included for read counting. `exon' by default."/>
9 <param name="gff_feature_attribute" type="text" value="gene_id" argument="-g" label="GFF gene identifier" help="Specify the attribute type used to group features (eg. exons) into meta-features (eg. genes), when GTF annotation is provided. `gene_id' by default. This attribute type is usually the gene identifier. This argument is useful for the meta-feature level summarization. Ex: if the 9th column is 'gene_id &quot;ENSG00000223972&quot;; gene_name &quot;DDX11L1&quot; gene_source &quot;havana&quot;' (GTF) or 'gene_id=ENSG00000223972; gene_name=DDX11L1; gene_source=havana' (GFF), the available attributes for this feature are 'gene_id', 'gene_name' and 'gene_source'."/>
10 <param name="summarization_level" type="boolean" truevalue=" -f" falsevalue="" argument="-f" label="On feature level" help="If specified, read summarization will be performed at the feature level. By default (-f is not specified), the read summarization is performed at the meta-feature level."/>
11 </macro>
6 </macros> 12 </macros>
7 <xrefs> 13 <xrefs>
8 <xref type="bio.tools">subread</xref> 14 <xref type="bio.tools">featurecounts</xref>
9 </xrefs> 15 </xrefs>
10 <requirements> 16 <requirements>
11 <requirement type="package" version="@TOOL_VERSION@">subread</requirement> 17 <requirement type="package" version="@TOOL_VERSION@">subread</requirement>
12 <requirement type="package" version="1.11">samtools</requirement> 18 <requirement type="package" version="1.16.1">samtools</requirement>
13 <requirement type="package" version="8.31">coreutils</requirement>
14 </requirements> 19 </requirements>
15 20
16 <version_command>featureCounts -v 2&gt;&amp;1 | grep .</version_command> 21 <version_command>featureCounts -v 2&gt;&amp;1 | grep .</version_command>
17 <command detect_errors="exit_code"><![CDATA[ 22 <command detect_errors="exit_code"><![CDATA[
18
19 ## Export fc path for its built-in annotation 23 ## Export fc path for its built-in annotation
20
21 export FC_PATH=\$(command -v featureCounts | sed 's@/bin/featureCounts$@@') && 24 export FC_PATH=\$(command -v featureCounts | sed 's@/bin/featureCounts$@@') &&
22 25
23 ## Check whether all alignments are from the same type (bam || sam) 26 ## Check whether all alignments are from the same type (bam || sam)
24 featureCounts 27 featureCounts
25 28
26 #if $anno.anno_select=="history": 29 #if $anno.anno_select=="history":
27 -a '$anno.reference_gene_sets' 30 -a '$anno.reference_gene_sets'
28 -F "GTF" 31 -F "GTF"
29 #elif $anno.anno_select=="cached": 32 #elif $anno.anno_select=="cached":
30 -a '$anno.reference_gene_sets_builtin.fields.path' 33 -a '$anno.reference_gene_sets_cached.fields.path'
31 -F "GTF" 34 -F "GTF"
32 #elif $anno.anno_select=="builtin": 35 #elif $anno.anno_select=="builtin":
33 -a \${FC_PATH}/annotation/${anno.bgenome}_RefSeq_exon.txt 36 -a \${FC_PATH}/annotation/${anno.bgenome}_RefSeq_exon.txt
34 -F "SAF" 37 -F "SAF"
35 #end if 38 #end if
42 -Q $read_filtering_parameters.mapping_quality 45 -Q $read_filtering_parameters.mapping_quality
43 $read_filtering_parameters.splitonly 46 $read_filtering_parameters.splitonly
44 $read_filtering_parameters.primary 47 $read_filtering_parameters.primary
45 $read_filtering_parameters.ignore_dup 48 $read_filtering_parameters.ignore_dup
46 49
47 -t '$extended_parameters.gff_feature_type' 50 #if $anno.anno_select!="builtin":
48 -g '$extended_parameters.gff_feature_attribute' 51 -t '$anno.gff_feature_type'
49 $extended_parameters.summarization_level 52 -g '$anno.gff_feature_attribute'
53 $anno.summarization_level
54 #end if
50 55
51 $extended_parameters.multifeatures.multifeat 56 $extended_parameters.multifeatures.multifeat
52 #if $extended_parameters.multifeatures.multifeat != "": 57 #if $extended_parameters.multifeatures.multifeat != "":
53 $extended_parameters.multifeatures.fraction 58 $extended_parameters.multifeatures.fraction
54 #end if 59 #end if
55
56
57 ## $extended_parameters.contribute_to_multiple_features
58 ## $extended_parameters.multimapping_enabled.multimapping_counts
59
60 ###if str($extended_parameters.multimapping_enabled.multimapping_counts) == " -M":
61 ## $extended_parameters.multimapping_enabled.fraction
62 ###end if -->
63 60
64 $extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads 61 $extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads
65 #if str($extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads) == "-J": 62 #if str($extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads) == "-J":
66 #if $extended_parameters.exon_exon_junction_read_counting_enabled.genome: 63 #if $extended_parameters.exon_exon_junction_read_counting_enabled.genome:
67 -G '$extended_parameters.exon_exon_junction_read_counting_enabled.genome' 64 -G '$extended_parameters.exon_exon_junction_read_counting_enabled.genome'
85 #end if 82 #end if
86 83
87 #if str($extended_parameters.read_extension_3p) != "0": 84 #if str($extended_parameters.read_extension_3p) != "0":
88 --readExtension3 $extended_parameters.read_extension_3p 85 --readExtension3 $extended_parameters.read_extension_3p
89 #end if 86 #end if
90 87
91 $pe_parameters.fragment_counting_enabled.fragment_counting 88 #if str($pe_parameters.paired_end_status) != "single_end":
92 #if str($pe_parameters.fragment_counting_enabled.fragment_counting) == " -p": 89 -p
93 $pe_parameters.fragment_counting_enabled.check_distance_enabled.check_distance 90 $pe_parameters.only_both_ends
94 #if str($pe_parameters.fragment_counting_enabled.check_distance_enabled.check_distance) == " -P": 91 $pe_parameters.exclude_chimerics
95 -d $pe_parameters.fragment_counting_enabled.check_distance_enabled.minimum_fragment_length 92 #if str($pe_parameters.paired_end_status) == "PE_fragments":
96 -D $pe_parameters.fragment_counting_enabled.check_distance_enabled.maximum_fragment_length 93 --countReadPairs
94 #if $pe_parameters.check_distance_enabled.checkFragLength:
95 --checkFragLength
96 --minFragLength $pe_parameters.check_distance_enabled.minimum_fragment_length
97 --maxFragLength $pe_parameters.check_distance_enabled.maximum_fragment_length
98 #end if
97 #end if 99 #end if
98 #end if 100 #end if
99
100 $pe_parameters.only_both_ends
101 $pe_parameters.exclude_chimerics
102 101
103 '${alignment}' 102 '${alignment}'
104 103
105 ## Remove comment and add sample name to header 104 ## Remove comment and add sample name to header
106 && grep -v "^#" "output" 105 && grep -v "^#" "output"
138 <param name="alignment" 137 <param name="alignment"
139 type="data" 138 type="data"
140 multiple="false" 139 multiple="false"
141 format="bam,sam" 140 format="bam,sam"
142 label="Alignment file" 141 label="Alignment file"
143 help="The input alignment file(s) where the gene expression has to be counted. The file can have a SAM or BAM format; but ALL files must be in the same format. Unless you are using a Gene annotation file from the History, these files must have the database/genome attribute already specified e.g. hg38, not the default: ?" > 142 help="The input alignment file(s) where the gene expression has to be counted. The file can have a SAM or BAM format; but ALL files must be in the same format. Unless you are using a Gene annotation file from the History, these files must have the database/genome attribute already specified e.g. hg38, not the default: ?">
144 </param> 143 </param>
145 144
146 <param name="strand_specificity" 145 <param name="strand_specificity"
147 type="select" 146 type="select"
148 label="Specify strand information" 147 label="Specify strand information"
155 154
156 <conditional name="anno"> 155 <conditional name="anno">
157 <param name="anno_select" type="select" label="Gene annotation file"> 156 <param name="anno_select" type="select" label="Gene annotation file">
158 <option value="builtin">featureCounts built-in</option> 157 <option value="builtin">featureCounts built-in</option>
159 <option value="cached" selected="True">locally cached</option> 158 <option value="cached" selected="True">locally cached</option>
160 <option value="history">in your history</option> 159 <option value="history">A GFF/GTF file in your history</option>
161 </param> 160 </param>
162 <when value="builtin"> 161 <when value="builtin">
163 <param name="bgenome" type="select" label="Select built-in genome" help="Built-in gene annotations for genomes hg38, hg19, mm10 and mm9 are included in featureCounts"> 162 <param name="bgenome" type="select" label="Select built-in genome" help="Built-in gene annotations for genomes hg38, hg19, mm10 and mm9 are included in featureCounts">
164 <options from_data_table="featurecounts_anno"> 163 <options from_data_table="featurecounts_anno">
165 <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/> 164 <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/>
165 <filter type="sort_by" column="1"/>
166 </options> 166 </options>
167 <validator type="no_options" message="An built-in annotation file is not available for the genome build associated with the selected input file"/>
167 </param> 168 </param>
168 </when> 169 </when>
169 <when value="cached"> 170 <when value="cached">
170 <param name="reference_gene_sets_builtin" type="select" label="Using locally cached annotation" help="If the annotation file you require is not listed here, please contact the Galaxy administrator"> 171 <param name="reference_gene_sets_cached" type="select" label="Using locally cached annotation" help="If the annotation file you require is not listed here, please contact the Galaxy administrator.">
171 <options from_data_table="gene_sets"> 172 <options from_data_table="gene_sets">
172 <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/> 173 <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/>
173 <filter type="sort_by" column="2" /> 174 <filter type="sort_by" column="2"/>
174 </options> 175 </options>
175 <validator type="no_options" message="An annotation file is not available for the build associated with the selected input file"/> 176 <validator type="no_options" message="A cached annotation file is not available for the genome build associated with the selected input file"/>
176 </param> 177 </param>
178 <expand macro="conditional_gff_opions"/>
177 </when> 179 </when>
178 <when value="history"> 180 <when value="history">
179 <param name="reference_gene_sets" 181 <param name="reference_gene_sets"
180 format="gff,gtf,gff3" 182 format="gff,gtf,gff3"
181 type="data" 183 type="data"
182 label="Gene annotation file" 184 label="Gene annotation file"
183 help="The program assumes that the provided annotation file is in GTF format. Make sure that the gene annotation file corresponds to the same reference genome as used for the alignment"> 185 help="The program assumes that the provided annotation file is in GFF/GTF format. Make sure that the gene annotation file corresponds to the same reference genome as used for the alignment.">
184 </param> 186 </param>
187 <expand macro="conditional_gff_opions"/>
185 </when> 188 </when>
186 </conditional> 189 </conditional>
187 190
188 <param name="format" 191 <param name="format"
189 type="select" 192 type="select"
198 type="boolean" 201 type="boolean"
199 truevalue="true" 202 truevalue="true"
200 falsevalue="false" 203 falsevalue="false"
201 checked="false" 204 checked="false"
202 label="Create gene-length file" 205 label="Create gene-length file"
203 help="Creates a tabular file that contains the effective (nucleotides used for counting reads) length of the feature; might be useful for estimating FPKM/RPKM" /> 206 help="Creates a tabular file that contains the effective (nucleotides used for counting reads) length of the feature; might be useful for estimating FPKM/RPKM"/>
204 207
205 208 <conditional name="pe_parameters">
206 <section name="pe_parameters" title="Options for paired-end reads"> 209 <param name="paired_end_status" type="select" label="Does the input have read pairs?" help="Were the bam files generated by aligning the output of a paired-end sequencing experiment? If yes, the tool can consider 2 reads = 1 read pair as 1 entity to count. Alternatively, you can opt to consider treating the read pairs as 2 individual reads to count seperately.">
207 <conditional name="fragment_counting_enabled"> 210 <option value="single_end" selected="True">No, single-end.</option>
208 211 <option value="PE_individual">Yes, paired-end but still count them as if individual reads.</option>
209 <param name="fragment_counting" 212 <option value="PE_fragments">Yes, paired-end and count them as 1 single fragment.</option>
210 type="select" 213 </param>
211 argument="-p" 214
212 checked="true" 215 <when value="single_end"/>
213 label="Count fragments instead of reads" 216 <when value="PE_individual">
214 help="If specified, fragments (or templates) will be counted instead of reads."> 217 <param name="only_both_ends"
215 <option value="" selected="true">Disabled; all reads/mates will be counted individually</option> 218 type="boolean"
216 <option value=" -p">Enabled; fragments (or templates) will be counted instead of reads</option> 219 truevalue=" -B"
217 </param> 220 falsevalue=""
218 221 argument="-B"
219 <when value=" -p"> 222 label="Only allow fragments with both reads aligned"
220 <conditional name="check_distance_enabled"> 223 help="If specified, only fragments that have both ends successfully aligned will be considered for summarization. This option is only applicable for paired-end reads."/>
221 <param name="check_distance" 224
222 type="boolean" 225 <param name="exclude_chimerics"
223 truevalue=" -P" 226 type="boolean"
224 falsevalue="" 227 truevalue=" -C"
225 argument="-P" 228 falsevalue=""
226 label="Check paired-end distance" 229 argument="-C"
227 help="If specified, paired-end distance will be checked when assigning fragments to meta-features or features. This option is only applicable when -p (Count fragments instead of reads) is specified. The distance thresholds should be specified using -d and -D (minimum and maximum fragment/template length) options." /> 230 checked="true"
228 <when value=" -P"> 231 label="Exclude chimeric fragments"
229 <param name="minimum_fragment_length" 232 help="If specified, the chimeric fragments (those fragments that have their two ends aligned to different chromosomes) will NOT be included for summarization. This option is only applicable for paired-end read data."/>
230 type="integer" 233 </when>
231 value="50" 234 <when value="PE_fragments">
232 argument="-d" 235 <conditional name="check_distance_enabled">
233 label="Minimum fragment/template length." /> 236 <param argument="--checkFragLength" type="select" label="Check paired-end distance" help="If specified, paired-end distance will be checked when assigning fragments to meta-features or features. This option is only applicable when -p (Count fragments instead of reads) is specified. The distance thresholds can be specified using -d and -D (minimum and maximum fragment/template length) options.">
234 <param name="maximum_fragment_length" 237 <option value="true">Check the distance between paired reads</option>
235 type="integer" 238 <option value="false" selected="True">Do not check</option>
236 value="600" 239 </param>
237 argument="-D" 240 <when value="true">
238 label="Maximum fragment/template length." /> 241 <param name="minimum_fragment_length"
239 </when> 242 type="integer"
240 <when value="" /> 243 value="50"
241 </conditional> 244 min="0"
242 </when> 245 argument="-d"
243 <when value="" /> 246 label="Minimum fragment/template length."/>
244 </conditional> 247 <param name="maximum_fragment_length"
245 248 type="integer"
246 <param name="only_both_ends" 249 value="600"
247 type="boolean" 250 min="1"
248 truevalue=" -B" 251 argument="-D"
249 falsevalue="" 252 label="Maximum fragment/template length."/>
250 argument="-B" 253 </when>
251 label="Only allow fragments with both reads aligned" 254 <when value="false"/>
252 help="If specified, only fragments that have both ends successfully aligned will be considered for summarization. This option is only applicable for paired-end reads." /> 255 </conditional>
253 256
254 <param name="exclude_chimerics" 257 <param name="only_both_ends"
255 type="boolean" 258 type="boolean"
256 truevalue=" -C" 259 truevalue=" -B"
257 falsevalue="" 260 falsevalue=""
258 argument="-C" 261 argument="-B"
259 checked="true" 262 label="Only allow fragments with both reads aligned"
260 label="Exclude chimeric fragments" 263 help="If specified, only fragments that have both ends successfully aligned will be considered for summarization. This option is only applicable for paired-end reads."/>
261 help="If specified, the chimeric fragments (those fragments that have their two ends aligned to different chromosomes) will NOT be included for summarization. This option is only applicable for paired-end read data." /> 264
262 </section> 265 <param name="exclude_chimerics"
266 type="boolean"
267 truevalue=" -C"
268 falsevalue=""
269 argument="-C"
270 checked="true"
271 label="Exclude chimeric fragments"
272 help="If specified, the chimeric fragments (those fragments that have their two ends aligned to different chromosomes) will NOT be included for summarization. This option is only applicable for paired-end read data."/>
273 </when>
274 </conditional>
263 275
264 <section name="read_filtering_parameters" title="Read filtering options"> 276 <section name="read_filtering_parameters" title="Read filtering options">
265 <param name="mapping_quality" 277 <param name="mapping_quality"
266 type="integer" 278 type="integer"
267 value="0" 279 value="0"
280 min="0"
268 argument="-Q" 281 argument="-Q"
269 label="Minimum mapping quality per read" 282 label="Minimum mapping quality per read"
270 help="The minimum mapping quality score a read must satisfy in order to be counted. For paired-end reads, at least one end should satisfy this criteria. 0 by default." /> 283 help="The minimum mapping quality score a read must satisfy in order to be counted. For paired-end reads, at least one end should satisfy this criteria. 0 by default."/>
271 <param name="splitonly" type="select" display="radio" label="Filter split alignments" help="Split alignments are alignments with CIGAR string containing 'N', e.g. exon spanning reads in RNASeq."> 284 <param name="splitonly" type="select" display="radio" label="Filter split alignments" help="Split alignments are alignments with CIGAR string containing 'N', e.g. exon spanning reads in RNASeq.">
272 <option value="">No filtering: count split and non-split alignments</option> 285 <option value="">No filtering: count split and non-split alignments</option>
273 <option value="--splitOnly">Count only split alignments (--splitOnly)</option> 286 <option value="--splitOnly">Count only split alignments (--splitOnly)</option>
274 <option value="--nonSplitOnly">Count only non-split alignments (--nonSplitOnly)</option> 287 <option value="--nonSplitOnly">Count only non-split alignments (--nonSplitOnly)</option>
275 </param> 288 </param>
276 <param type="boolean" 289 <param type="boolean"
277 truevalue=" --primary" 290 truevalue=" --primary"
278 falsevalue="" 291 falsevalue=""
279 argument="--primary" 292 argument="--primary"
280 label="Only count primary alignments" 293 label="Only count primary alignments"
281 help="If specified, only primary alignments will be counted. Primary and secondary alignments are identified using bit 0x100 in theFlag field of SAM/BAM files. All primary alignments in a dataset will be counted regardless of whether they are from multi-mapping reads or not ('-M' is ignored)." /> 294 help="If specified, only primary alignments will be counted. Primary and secondary alignments are identified using bit 0x100 in theFlag field of SAM/BAM files. All primary alignments in a dataset will be counted regardless of whether they are from multi-mapping reads or not ('-M' is ignored)."/>
282 <param name="ignore_dup" 295 <param name="ignore_dup"
283 type="boolean" 296 type="boolean"
284 truevalue=" --ignoreDup" 297 truevalue=" --ignoreDup"
285 falsevalue="" 298 falsevalue=""
286 argument="--ignoreDup" 299 argument="--ignoreDup"
287 label="Ignore reads marked as duplicate" 300 label="Ignore reads marked as duplicate"
288 help="If specified, reads that were marked as duplicates will be ignored. Bit Ox400 in the FLAG field of a SAM/BAM file is used for identifying duplicate reads. In paired end data, the entire read pair will be ignored if at least one end is found to be a duplicate read." /> 301 help="If specified, reads that were marked as duplicates will be ignored. Bit Ox400 in the FLAG field of a SAM/BAM file is used for identifying duplicate reads. In paired end data, the entire read pair will be ignored if at least one end is found to be a duplicate read."/>
289 </section> 302 </section>
290 303
291 <section name="extended_parameters" title="Advanced options"> 304 <section name="extended_parameters" title="Advanced options">
292 <param name="gff_feature_type"
293 type="text"
294 value="exon"
295 argument="-t"
296 label="GFF feature type filter"
297 help="Specify the feature type. Only rows which have the matched matched feature type in the provided GTF annotation file will be included for read counting. `exon' by default." />
298
299 <param name="gff_feature_attribute"
300 type="text"
301 value="gene_id"
302 argument="-g"
303 label="GFF gene identifier"
304 help="Specify the attribute type used to group features (eg. exons) into meta-features (eg. genes), when GTF annotation is provided. `gene_id' by default. This attribute type is usually the gene identifier. This argument is useful for the meta-feature level summarization." />
305
306 <param name="summarization_level"
307 type="boolean"
308 truevalue=" -f"
309 falsevalue=""
310 argument="-f"
311 label="On feature level"
312 help="If specified, read summarization will be performed at the feature level. By default (-f is not specified), the read summarization is performed at the meta-feature level." />
313
314 <conditional name = "multifeatures"> 305 <conditional name = "multifeatures">
315 <param name="multifeat" type="select" label="Allow reads to map to multiple features" help="Setting -O, -M and --fraction"> 306 <param name="multifeat" type="select" label="Allow reads to map to multiple features" help="Setting -O, -M and --fraction">
316 <option value="" selected="true">Disabled: reads that align to multiple features or overlapping features are excluded</option> 307 <option value="" selected="true">Disabled: reads that align to multiple features or overlapping features are excluded</option>
317 <option value="-M">Enabled: multi-mapping reads are included (-M)</option> 308 <option value="-M">Enabled: multi-mapping reads are included (-M)</option>
318 <option value="-O">Enabled: multi-overlapping features are included (-O)</option> 309 <option value="-O">Enabled: multi-overlapping features are included (-O)</option>
319 <option value="-O -M">Enabled: both multi-mapping and multi-overlapping features are included (-M -O)</option> 310 <option value="-O -M">Enabled: both multi-mapping and multi-overlapping features are included (-M -O)</option>
320 </param> 311 </param>
321 <when value=""/> 312 <when value=""/>
322 <when value="-M"> 313 <when value="-M">
323 <param name="fraction" 314 <param type="boolean"
324 type="boolean"
325 truevalue="--fraction" 315 truevalue="--fraction"
326 falsevalue="" 316 falsevalue=""
327 argument="--fraction" 317 argument="--fraction"
328 label="Assign fractions to multi-mapping reads" 318 label="Assign fractions to multi-mapping reads"
329 help="If specified, a fractional count 1/x will be generated for each multi-mapping read, where x is the number of alignments (indicated by 'NH' tag) reported for the read."/> 319 help="If specified, a fractional count 1/x will be generated for each multi-mapping read, where x is the number of alignments (indicated by 'NH' tag) reported for the read."/>
330 </when> 320 </when>
331 <when value="-O"> 321 <when value="-O">
332 <param name="fraction" 322 <param type="boolean"
333 type="boolean"
334 truevalue="--fraction" 323 truevalue="--fraction"
335 falsevalue="" 324 falsevalue=""
336 argument="--fraction" 325 argument="--fraction"
337 label="Assign fractions to multi-overlapping features" 326 label="Assign fractions to multi-overlapping features"
338 help="If specified, a fractional count 1/y will be generated for each multi-overlapping feature, where y is the number of features overlapping with the read."/> 327 help="If specified, a fractional count 1/y will be generated for each multi-overlapping feature, where y is the number of features overlapping with the read."/>
339 </when> 328 </when>
340 <when value="-O -M"> 329 <when value="-O -M">
341 <param name="fraction" 330 <param type="boolean"
342 type="boolean"
343 truevalue="--fraction" 331 truevalue="--fraction"
344 falsevalue="" 332 falsevalue=""
345 argument="--fraction" 333 argument="--fraction"
346 label="Assign fractions to both multi-mapping reads and multi-overlapping features" 334 label="Assign fractions to both multi-mapping reads and multi-overlapping features"
347 help="If specified, a fractional count 1/(x*y) will be generated, where x is the number of alignments (indicated by 'NH' tag) and y the number of overlapping features."/> 335 help="If specified, a fractional count 1/(x*y) will be generated, where x is the number of alignments (indicated by 'NH' tag) and y the number of overlapping features."/>
348 </when> 336 </when>
349 </conditional> 337 </conditional>
350 338
351 <conditional name="exon_exon_junction_read_counting_enabled"> 339 <conditional name="exon_exon_junction_read_counting_enabled">
352 <param name="count_exon_exon_junction_reads" argument="-J" type="boolean" truevalue="-J" falsevalue="" 340 <param name="count_exon_exon_junction_reads" type="select" argument="-J" label="Exon-exon junctions" help="Junctions are identified from those exon-spanning reads (containing ‘N’ in CIGAR string) in input data. The output result includes names of primary and secondary genes that overlap at least one of the two splice sites of a junction.">
353 label="Exon-exon junctions" 341 <option value="-J">Count reads supporting each exon-exon junction.</option>
354 help="If specified, reads supporting each exon-exon junction will be counted" /> 342 <option value="" selected="True">Do not count</option>
343 </param>
355 <when value="-J"> 344 <when value="-J">
356 <param name="genome" argument="-G" type="data" format="fasta" optional="true" 345 <param name="genome" argument="-G" type="data" format="fasta" optional="true"
357 label="Reference sequence file" 346 label="Reference sequence file"
358 help="The FASTA-format file that contains the reference sequences used in read mapping can be used to improve read counting for junctions" /> 347 help="The FASTA-format file that contains the reference sequences used in read mapping can be used to improve read counting for junctions"/>
359 </when> 348 </when>
360 <when value="" /> 349 <when value=""/>
361 </conditional> 350 </conditional>
362 351
363 <param name="long_reads" argument="-L" type="boolean" truevalue="-L" falsevalue="" 352 <param name="long_reads" argument="-L" type="boolean" truevalue="-L" falsevalue=""
364 label="Long reads" 353 label="Long reads"
365 help="If specified, long reads such as Nanopore and PacBio reads will be counted. Long read counting can only run in one thread and only reads (not read-pairs) can be counted." /> 354 help="If specified, long reads such as Nanopore and PacBio reads will be counted. Long read counting can only run in one thread and only reads (not read-pairs) can be counted."/>
366 355
367 <param name="by_read_group" argument="--byReadGroup" type="boolean" truevalue="--byReadGroup" falsevalue="" 356 <param name="by_read_group" argument="--byReadGroup" type="boolean" truevalue="--byReadGroup" falsevalue=""
368 label="Count reads by read group" 357 label="Count reads by read group"
369 help="If specified, reads are counted for each read group separately. The 'RG' tag must be present in the input BAM/SAM alignment files." /> 358 help="If specified, reads are counted for each read group separately. The 'RG' tag must be present in the input BAM/SAM alignment files."/>
370
371 359
372 <param name="largest_overlap" 360 <param name="largest_overlap"
373 type="boolean" 361 type="boolean"
374 truevalue=" --largestOverlap" 362 truevalue=" --largestOverlap"
375 falsevalue="" 363 falsevalue=""
376 argument="--largestOverlap" 364 argument="--largestOverlap"
377 label="Largest overlap" 365 label="Largest overlap"
378 help="If specified, reads (or fragments) will be assigned to the target that has the largest number of overlapping bases" /> 366 help="If specified, reads (or fragments) will be assigned to the target that has the largest number of overlapping bases"/>
379 367
380 <param name="min_overlap" 368 <param name="min_overlap"
381 type="integer" 369 type="integer"
382 value="1" 370 value="1"
383 argument="--minOverlap" 371 argument="--minOverlap"
384 label="Minimum bases of overlap" 372 label="Minimum bases of overlap"
385 help="Specify the minimum required number of overlapping bases between a read (or a fragment) and a feature. 1 by default. If a negative value is provided, the read will be extended from both ends." /> 373 help="Specify the minimum required number of overlapping bases between a read (or a fragment) and a feature. 1 by default. If a negative value is provided, the read will be extended from both ends."/>
386 374
387 <param name="frac_overlap" 375 <param name="frac_overlap"
388 type="integer" 376 type="integer"
389 value="0" 377 value="0"
390 min="0" 378 min="0"
391 max="1" 379 max="1"
392 argument="--fracOverlap" 380 argument="--fracOverlap"
393 label="Minimum fraction (of read) overlapping a feature" 381 label="Minimum fraction (of read) overlapping a feature"
394 help="Specify the minimum required fraction of overlapping bases between a read (or a fragment) and a feature. Value should be within range [0,1]. 0 by default. Number of overlapping bases is counted from both reads if paired end. Both this option and '--minOverlap' need to be satisfied for read assignment." /> 382 help="Specify the minimum required fraction of overlapping bases between a read (or a fragment) and a feature. Value should be within range [0,1]. 0 by default. Number of overlapping bases is counted from both reads if paired end. Both this option and '--minOverlap' need to be satisfied for read assignment."/>
395 383
396 <param name="frac_overlap_feature" 384 <param name="frac_overlap_feature"
397 type="integer" 385 type="integer"
398 value="0" 386 value="0"
399 min="0" 387 min="0"
400 max="1" 388 max="1"
401 argument="--fracOverlapFeature" 389 argument="--fracOverlapFeature"
402 label="Minimum fraction (of feature) overlapping a read" 390 label="Minimum fraction (of feature) overlapping a read"
403 help="Specify the minimum required fraction of bases included in a feature overlapping bases between a read (or a read-pair). Value should be within range [0,1]. 0 by default." /> 391 help="Specify the minimum required fraction of bases included in a feature overlapping bases between a read (or a read-pair). Value should be within range [0,1]. 0 by default."/>
404 392
405 <param name="read_extension_5p" 393 <param name="read_extension_5p"
406 type="integer" 394 type="integer"
407 value="0" 395 value="0"
396 min="0"
408 argument="--readExtension5" 397 argument="--readExtension5"
409 label="Read 5' extension" 398 label="Read 5' extension"
410 help="Reads are extended upstream by ... bases from their 5' end" /> 399 help="Reads are extended upstream by ... bases from their 5' end"/>
411 400
412 <param name="read_extension_3p" 401 <param name="read_extension_3p"
413 type="integer" 402 type="integer"
414 value="0" 403 value="0"
404 min="0"
415 argument="--readExtension3" 405 argument="--readExtension3"
416 label="Read 3' extension" 406 label="Read 3' extension"
417 help="Reads are extended upstream by ... bases from their 3' end" /> 407 help="Reads are extended upstream by ... bases from their 3' end"/>
418 408
419 <param name="read_reduction" 409 <param name="read_reduction"
420 type="select" 410 type="select"
421 label="Reduce read to single position" 411 label="Reduce read to single position"
422 argument="--read2pos" 412 argument="--read2pos"
429 <param type="boolean" 419 <param type="boolean"
430 truevalue="-R BAM" 420 truevalue="-R BAM"
431 falsevalue="" 421 falsevalue=""
432 argument="-R" 422 argument="-R"
433 label="Annotates the alignment file with 'XS:Z:'-tags to described per read or read-pair the corresponding assigned feature(s)." 423 label="Annotates the alignment file with 'XS:Z:'-tags to described per read or read-pair the corresponding assigned feature(s)."
434 help="" /> 424 help=""/>
435 425
436 </section> 426 </section>
437 </inputs> 427 </inputs>
438 <outputs> 428 <outputs>
439 <data format="tabular" 429 <data format="tabular"
440 name="output_medium" 430 name="output_medium"
441 label="${tool.name} on ${on_string}: Counts (with length)"> 431 label="${tool.name} on ${on_string}: Counts (with length)">
442 <filter>format == "tabdel_medium"</filter> 432 <filter>format == "tabdel_medium"</filter>
443 <actions> 433 <actions>
444 <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier},Length" /> 434 <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier},Length"/>
445 </actions> 435 </actions>
446 </data> 436 </data>
447 437
448 <data format="bam" 438 <data format="bam"
449 name="output_bam" 439 name="output_bam"
454 <data format="tabular" 444 <data format="tabular"
455 name="output_short" 445 name="output_short"
456 label="${tool.name} on ${on_string}: Counts"> 446 label="${tool.name} on ${on_string}: Counts">
457 <filter>format == "tabdel_short"</filter> 447 <filter>format == "tabdel_short"</filter>
458 <actions> 448 <actions>
459 <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier}" /> 449 <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier}"/>
460 </actions> 450 </actions>
461 </data> 451 </data>
462 452
463 <data format="tabular" 453 <data format="tabular"
464 name="output_full" 454 name="output_full"
465 label="${tool.name} on ${on_string}: Counts (with location)"> 455 label="${tool.name} on ${on_string}: Counts (with location)">
466 <filter>format == "tabdel_full"</filter> 456 <filter>format == "tabdel_full"</filter>
467 <actions> 457 <actions>
468 <action name="column_names" type="metadata" default="Geneid,Chr,Start,End,Strand,Length,${alignment.element_identifier}" /> 458 <action name="column_names" type="metadata" default="Geneid,Chr,Start,End,Strand,Length,${alignment.element_identifier}"/>
469 </actions> 459 </actions>
470 </data> 460 </data>
471 461
472 <data format="tabular" 462 <data format="tabular"
473 name="output_summary" 463 name="output_summary"
474 label="${tool.name} on ${on_string}: Summary"> 464 label="${tool.name} on ${on_string}: Summary">
475 <actions> 465 <actions>
476 <action name="column_names" type="metadata" default="Status,${alignment.element_identifier}" /> 466 <action name="column_names" type="metadata" default="Status,${alignment.element_identifier}"/>
477 </actions> 467 </actions>
478 </data> 468 </data>
479 469
480 <data format="tabular" 470 <data format="tabular"
481 name="output_feature_lengths" 471 name="output_feature_lengths"
482 label="${tool.name} on ${on_string}: Feature lengths"> 472 label="${tool.name} on ${on_string}: Feature lengths">
483 <filter>include_feature_length_file</filter> 473 <filter>include_feature_length_file</filter>
484 <actions> 474 <actions>
485 <action name="column_names" type="metadata" default="Feature,Length" /> 475 <action name="column_names" type="metadata" default="Feature,Length"/>
486 </actions> 476 </actions>
487 </data> 477 </data>
488 478
489 <data name="output_jcounts" format="tabular" 479 <data name="output_jcounts" format="tabular"
490 label="${tool.name} on ${on_string}: Junction counts"> 480 label="${tool.name} on ${on_string}: Junction counts">
491 <filter>extended_parameters['exon_exon_junction_read_counting_enabled']['count_exon_exon_junction_reads']</filter> 481 <filter>extended_parameters['exon_exon_junction_read_counting_enabled']['count_exon_exon_junction_reads']</filter>
492 <actions> 482 <actions>
493 <action name="column_names" type="metadata" 483 <action name="column_names" type="metadata"
494 default="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,${alignment.element_identifier}" /> 484 default="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,${alignment.element_identifier}"/>
495 </actions> 485 </actions>
496 </data> 486 </data>
497 </outputs> 487 </outputs>
498 <tests> 488 <tests>
499 <test expect_num_outputs="3"> 489 <test expect_num_outputs="3">
500 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" /> 490 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
501 <param name="anno_select" value="history"/> 491 <param name="anno_select" value="history"/>
502 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" /> 492 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
503 <param name="format" value="tabdel_medium" /> 493 <param name="format" value="tabdel_medium"/>
504 <param name="include_feature_length_file" value="true"/> 494 <param name="include_feature_length_file" value="true"/>
505 <output name="output_medium" file="output_1_medium.tab"> 495 <output name="output_medium" file="output_1_medium.tab">
506 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/> 496 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/>
507 </output> 497 </output>
508 <output name="output_summary" file="output_1_summary.tab"> 498 <output name="output_summary" file="output_1_summary.tab">
509 <metadata name="column_names" value="Status,featureCounts_input1.bam"/> 499 <metadata name="column_names" value="Status,featureCounts_input1.bam"/>
510 </output> 500 </output>
511 </test> 501 </test>
512 <test expect_num_outputs="3"> 502 <test expect_num_outputs="3">
513 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" /> 503 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
514 <param name="anno_select" value="history"/> 504 <param name="anno_select" value="history"/>
515 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" /> 505 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
516 <param name="format" value="tabdel_full" /> 506 <param name="format" value="tabdel_full"/>
517 <param name="include_feature_length_file" value="true"/> 507 <param name="include_feature_length_file" value="true"/>
518 <output name="output_full" file="output_1_full.tab"> 508 <output name="output_full" file="output_1_full.tab">
519 <metadata name="column_names" value="Geneid,Chr,Start,End,Strand,Length,featureCounts_input1.bam"/> 509 <metadata name="column_names" value="Geneid,Chr,Start,End,Strand,Length,featureCounts_input1.bam"/>
520 </output> 510 </output>
521 <output name="output_summary" file="output_1_summary.tab"> 511 <output name="output_summary" file="output_1_summary.tab">
524 <output name="output_feature_lengths" file="output_feature_lengths.tab"> 514 <output name="output_feature_lengths" file="output_feature_lengths.tab">
525 <metadata name="column_names" value="Feature,Length"/> 515 <metadata name="column_names" value="Feature,Length"/>
526 </output> 516 </output>
527 </test> 517 </test>
528 <test expect_num_outputs="4"> 518 <test expect_num_outputs="4">
529 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" /> 519 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
530 <param name="anno_select" value="history"/> 520 <param name="anno_select" value="history"/>
531 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" /> 521 <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
532 <param name="format" value="tabdel_short" /> 522 <param name="format" value="tabdel_short"/>
533 <param name="include_feature_length_file" value="true"/> 523 <param name="include_feature_length_file" value="true"/>
534 <param name="count_exon_exon_junction_reads" value="-J"/> 524 <param name="count_exon_exon_junction_reads" value="-J"/>
535 <output name="output_short" file="output_1_short.tab"> 525 <output name="output_short" file="output_1_short.tab">
536 <metadata name="column_names" value="Geneid,featureCounts_input1.bam"/> 526 <metadata name="column_names" value="Geneid,featureCounts_input1.bam"/>
537 </output> 527 </output>
542 <metadata name="column_names" value="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,featureCounts_input1.bam"/> 532 <metadata name="column_names" value="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,featureCounts_input1.bam"/>
543 </output> 533 </output>
544 </test> 534 </test>
545 <!-- Ensure featureCounts built-in annotation works --> 535 <!-- Ensure featureCounts built-in annotation works -->
546 <test expect_num_outputs="3"> 536 <test expect_num_outputs="3">
547 <param name="alignment" value="pairend_strandspecific_51mer_hg19_chr1_1-100000.bam" ftype="bam" dbkey="hg19" /> 537 <param name="alignment" value="pairend_strandspecific_51mer_hg19_chr1_1-100000.bam" ftype="bam" dbkey="hg19"/>
548 <param name="anno_select" value="builtin"/> 538 <param name="anno_select" value="builtin"/>
549 <param name="format" value="tabdel_short" /> 539 <param name="format" value="tabdel_short"/>
540 <conditional name="pe_parameters">
541 <param name="paired_end_status" value="PE_individual"/>
542 </conditional>
550 <section name="extended_parameters"> 543 <section name="extended_parameters">
551 <param name="R" value="true" /> 544 <param name="R" value="true"/>
552 </section> 545 </section>
553 <output name="output_short" file="output_builtin_hg19.tab"> 546 <output name="output_short" file="output_builtin_hg19.tab">
554 <metadata name="column_names" value="Geneid,pairend_strandspecific_51mer_hg19_chr1_1-100000.bam"/> 547 <metadata name="column_names" value="Geneid,pairend_strandspecific_51mer_hg19_chr1_1-100000.bam"/>
555 </output> 548 </output>
556 <output name="output_summary" file="output_summary_builtin_hg19.tab"/> 549 <output name="output_summary" file="output_summary_builtin_hg19.tab"/>
557 <output name="output_bam" file="output.bam" ftype="bam"/> 550 <output name="output_bam" file="output.bam" ftype="bam"/>
558 </test> 551 </test>
559 <!-- Ensure cached GTFs work --> 552 <!-- Ensure cached GTFs work -->
560 <test expect_num_outputs="3"> 553 <test expect_num_outputs="3">
561 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" /> 554 <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
562 <param name="anno_select" value="cached"/> 555 <param name="anno_select" value="cached"/>
563 <param name="format" value="tabdel_medium" /> 556 <param name="format" value="tabdel_medium"/>
564 <param name="include_feature_length_file" value="true"/> 557 <param name="include_feature_length_file" value="true"/>
565 <output name="output_medium" file="output_1_medium.tab"> 558 <output name="output_medium" file="output_1_medium.tab">
566 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/> 559 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/>
567 </output> 560 </output>
568 <output name="output_summary" file="output_1_summary.tab"> 561 <output name="output_summary" file="output_1_summary.tab">
569 <metadata name="column_names" value="Status,featureCounts_input1.bam"/> 562 <metadata name="column_names" value="Status,featureCounts_input1.bam"/>
570 </output> 563 </output>
571 </test> 564 </test>
572 <!-- Ensure BAM output works --> 565 <!-- Ensure BAM output works -->
573 <test> 566 <test>
574 <param name="alignment" value="subset.sorted.bam" ftype="bam" /> 567 <param name="alignment" value="subset.sorted.bam" ftype="bam"/>
575 <param name="anno_select" value="history" /> 568 <param name="anno_select" value="history"/>
576 <param name="reference_gene_sets" value="small.gtf" ftype="gtf" /> 569 <param name="reference_gene_sets" value="small.gtf" ftype="gtf"/>
577 <section name="extended_parameters" > 570 <section name="extended_parameters">
578 <param name="R" value="true" /> 571 <param name="R" value="true"/>
579 </section> 572 </section>
580 <output name="output_bam" value="subset.sorted.featurecounts.bam" compare="sim_size"/> 573 <output name="output_bam" value="subset.sorted.featurecounts.bam" compare="sim_size"/>
581 </test> 574 </test>
582 </tests> 575 </tests>
583 576
607 600
608 ====== ==== ======= ======= ====== 601 ====== ==== ======= ======= ======
609 GeneID Chr Start End Strand 602 GeneID Chr Start End Strand
610 ====== ==== ======= ======= ====== 603 ====== ==== ======= ======= ======
611 497097 chr1 3204563 3207049 - 604 497097 chr1 3204563 3207049 -
612 497097 chr1 3411783 3411982 - 605 497098 chr1 3411783 3411982 -
613 497097 chr1 3660633 3661579 - 606 497099 chr1 3660633 3661579 -
614 ====== ==== ======= ======= ====== 607 ====== ==== ======= ======= ======
615 608
616 These annotation files can be found in the `Subread package`_. You can see the version of Subread used by this wrapper in the tool form above under `Options > Requirements`. To create the files, the annotations were downloaded from NCBI RefSeq database and then adapted by merging overlapping exons from the same gene to form a set of disjoint exons for each gene. Genes with the same Entrez gene identifiers were also merged into one gene. See the `Subread User's Guide`_ for more information. Gene names can be obtained for these Entrez identifiers with the Galaxy **annotateMyIDs** tool. 609 These annotation files can be found in the `Subread package`_. You can see the version of Subread used by this wrapper in the tool form above under `Options > Requirements`. To create the files, the annotations were downloaded from NCBI RefSeq database and then adapted by merging overlapping exons from the same gene to form a set of disjoint exons for each gene. Genes with the same Entrez gene identifiers were also merged into one gene. See the `Subread User's Guide`_ for more information. Gene names can be obtained for these Entrez identifiers with the Galaxy **annotateMyIDs** tool.
617 610
618 Output format 611 Output format
625 ]]></help> 618 ]]></help>
626 <citations> 619 <citations>
627 <citation type="doi">10.1093/bioinformatics/btt656</citation> 620 <citation type="doi">10.1093/bioinformatics/btt656</citation>
628 </citations> 621 </citations>
629 </tool> 622 </tool>
623