changeset 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
files featurecounts.xml
diffstat 1 files changed, 159 insertions(+), 165 deletions(-) [+]
line wrap: on
line diff
--- a/featurecounts.xml	Sat Dec 04 22:18:02 2021 +0000
+++ b/featurecounts.xml	Fri Feb 24 14:02:04 2023 +0000
@@ -1,23 +1,26 @@
-<tool id="featurecounts" name="featureCounts" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.05">
+<tool id="featurecounts" name="featureCounts" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="20.09">
     <description>Measure gene expression in RNA-Seq experiments from SAM or BAM files</description>
     <macros>
-        <token name="@TOOL_VERSION@">2.0.1</token>
-        <token name="@VERSION_SUFFIX@">2</token>
+        <token name="@TOOL_VERSION@">2.0.3</token>
+        <token name="@VERSION_SUFFIX@">0</token>
+
+        <macro name="conditional_gff_opions">
+            <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."/>
+            <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'."/>
+            <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."/>
+        </macro>
     </macros>
     <xrefs>
-        <xref type="bio.tools">subread</xref>
+        <xref type="bio.tools">featurecounts</xref>
     </xrefs>
     <requirements>
         <requirement type="package" version="@TOOL_VERSION@">subread</requirement>
-        <requirement type="package" version="1.11">samtools</requirement>
-        <requirement type="package" version="8.31">coreutils</requirement>
+        <requirement type="package" version="1.16.1">samtools</requirement>
     </requirements>
 
     <version_command>featureCounts -v 2&gt;&amp;1 | grep .</version_command>
     <command detect_errors="exit_code"><![CDATA[
-
         ## Export fc path for its built-in annotation
-
         export FC_PATH=\$(command -v featureCounts | sed 's@/bin/featureCounts$@@') &&
 
         ## Check whether all alignments are from the same type (bam || sam)
@@ -27,7 +30,7 @@
                 -a '$anno.reference_gene_sets'
                 -F "GTF"
             #elif $anno.anno_select=="cached":
-                -a '$anno.reference_gene_sets_builtin.fields.path'
+                -a '$anno.reference_gene_sets_cached.fields.path'
                 -F "GTF"
             #elif $anno.anno_select=="builtin":
                 -a \${FC_PATH}/annotation/${anno.bgenome}_RefSeq_exon.txt
@@ -44,23 +47,17 @@
             $read_filtering_parameters.primary
             $read_filtering_parameters.ignore_dup
 
-            -t '$extended_parameters.gff_feature_type'
-            -g '$extended_parameters.gff_feature_attribute'
-                $extended_parameters.summarization_level
+            #if $anno.anno_select!="builtin":
+                -t '$anno.gff_feature_type'
+                -g '$anno.gff_feature_attribute'
+                    $anno.summarization_level
+            #end if
 
                 $extended_parameters.multifeatures.multifeat
                 #if $extended_parameters.multifeatures.multifeat != "":
                     $extended_parameters.multifeatures.fraction
                 #end if
 
-
-                ## $extended_parameters.contribute_to_multiple_features
-                ## $extended_parameters.multimapping_enabled.multimapping_counts
-
-                ###if str($extended_parameters.multimapping_enabled.multimapping_counts) == " -M":
-                ##    $extended_parameters.multimapping_enabled.fraction
-                ###end if -->
-
                 $extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads
                 #if str($extended_parameters.exon_exon_junction_read_counting_enabled.count_exon_exon_junction_reads) == "-J":
                     #if $extended_parameters.exon_exon_junction_read_counting_enabled.genome:
@@ -87,19 +84,21 @@
                 #if str($extended_parameters.read_extension_3p) != "0":
                     --readExtension3 $extended_parameters.read_extension_3p
                 #end if
-
-                $pe_parameters.fragment_counting_enabled.fragment_counting
-                #if str($pe_parameters.fragment_counting_enabled.fragment_counting) == " -p":
-                    $pe_parameters.fragment_counting_enabled.check_distance_enabled.check_distance
-                    #if str($pe_parameters.fragment_counting_enabled.check_distance_enabled.check_distance) == " -P":
-                        -d $pe_parameters.fragment_counting_enabled.check_distance_enabled.minimum_fragment_length
-                        -D $pe_parameters.fragment_counting_enabled.check_distance_enabled.maximum_fragment_length
+                
+                #if str($pe_parameters.paired_end_status) != "single_end":
+                    -p
+                    $pe_parameters.only_both_ends
+                    $pe_parameters.exclude_chimerics
+                    #if str($pe_parameters.paired_end_status) == "PE_fragments":
+                        --countReadPairs
+                        #if $pe_parameters.check_distance_enabled.checkFragLength:
+                            --checkFragLength
+                            --minFragLength $pe_parameters.check_distance_enabled.minimum_fragment_length
+                            --maxFragLength $pe_parameters.check_distance_enabled.maximum_fragment_length
+                        #end if
                     #end if
                 #end if
 
-                $pe_parameters.only_both_ends
-                $pe_parameters.exclude_chimerics
-
         '${alignment}'
 
         ## Remove comment and add sample name to header
@@ -140,7 +139,7 @@
                multiple="false"
                format="bam,sam"
                label="Alignment file"
-               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: ?" >
+               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: ?">
         </param>
 
         <param name="strand_specificity"
@@ -157,31 +156,35 @@
             <param name="anno_select" type="select" label="Gene annotation file">
                 <option value="builtin">featureCounts built-in</option>
                 <option value="cached" selected="True">locally cached</option>
-                <option value="history">in your history</option>
+                <option value="history">A GFF/GTF file in your history</option>
             </param>
             <when value="builtin">
                 <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">
                     <options from_data_table="featurecounts_anno">
                         <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/>
+                        <filter type="sort_by" column="1"/>
                     </options>
+                    <validator type="no_options" message="An built-in annotation file is not available for the genome build associated with the selected input file"/>
                 </param>
             </when>
             <when value="cached">
-                <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">
+                <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.">
                     <options from_data_table="gene_sets">
                         <filter type="data_meta" key="dbkey" ref="alignment" column="dbkey"/>
-                        <filter type="sort_by" column="2" />
+                        <filter type="sort_by" column="2"/>
                     </options>
-                    <validator type="no_options" message="An annotation file is not available for the build associated with the selected input file"/>
+                    <validator type="no_options" message="A cached annotation file is not available for the genome build associated with the selected input file"/>
                 </param>
+                <expand macro="conditional_gff_opions"/>
             </when>
             <when value="history">
                 <param name="reference_gene_sets"
                        format="gff,gtf,gff3"
                        type="data"
                        label="Gene annotation file"
-                       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">
+                       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.">
                 </param>
+                <expand macro="conditional_gff_opions"/>
             </when>
         </conditional>
 
@@ -200,74 +203,84 @@
                falsevalue="false"
                checked="false"
                label="Create gene-length file"
-               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" />
-
+               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"/>
 
-        <section name="pe_parameters" title="Options for paired-end reads">
-            <conditional name="fragment_counting_enabled">
+        <conditional name="pe_parameters">
+            <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.">
+                <option value="single_end" selected="True">No, single-end.</option>
+                <option value="PE_individual">Yes, paired-end but still count them as if individual reads.</option>
+                <option value="PE_fragments">Yes, paired-end and count them as 1 single fragment.</option>
+            </param>
 
-                <param name="fragment_counting"
-                       type="select"
-                       argument="-p"
-                       checked="true"
-                       label="Count fragments instead of reads"
-                       help="If specified, fragments (or templates) will be counted instead of reads.">
-                    <option value="" selected="true">Disabled; all reads/mates will be counted individually</option>
-                    <option value=" -p">Enabled; fragments (or templates) will be counted instead of reads</option>
-                </param>
+            <when value="single_end"/>
+            <when value="PE_individual">
+                <param name="only_both_ends"
+                    type="boolean"
+                    truevalue=" -B"
+                    falsevalue=""
+                    argument="-B"
+                    label="Only allow fragments with both reads aligned"
+                    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."/>
 
-                <when value=" -p">
-                    <conditional name="check_distance_enabled">
-                        <param name="check_distance"
-                            type="boolean"
-                            truevalue=" -P"
-                            falsevalue=""
-                            argument="-P"
-                            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 should be specified using -d and -D (minimum and maximum fragment/template length) options." />
-                        <when value=" -P">
-                            <param name="minimum_fragment_length"
-                                   type="integer"
-                                   value="50"
-                                   argument="-d"
-                                   label="Minimum fragment/template length." />
-                            <param name="maximum_fragment_length"
-                                   type="integer"
-                                   value="600"
-                                   argument="-D"
-                                   label="Maximum fragment/template length." />
-                        </when>
-                        <when value="" />
-                    </conditional>
-                </when>
-                <when value="" />
-            </conditional>
+                <param name="exclude_chimerics"
+                    type="boolean"
+                    truevalue=" -C"
+                    falsevalue=""
+                    argument="-C"
+                    checked="true"
+                    label="Exclude chimeric fragments"
+                    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."/>         
+            </when>
+            <when value="PE_fragments">
+                <conditional name="check_distance_enabled">
+                    <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.">
+                        <option value="true">Check the distance between paired reads</option>
+                        <option value="false" selected="True">Do not check</option>
+                    </param>
+                    <when value="true">
+                        <param name="minimum_fragment_length"
+                            type="integer"
+                            value="50"
+                            min="0"
+                            argument="-d"
+                            label="Minimum fragment/template length."/>
+                        <param name="maximum_fragment_length"
+                            type="integer"
+                            value="600"
+                            min="1"
+                            argument="-D"
+                            label="Maximum fragment/template length."/>
+                    </when>
+                    <when value="false"/>
+                </conditional>
+                
+                <param name="only_both_ends"
+                    type="boolean"
+                    truevalue=" -B"
+                    falsevalue=""
+                    argument="-B"
+                    label="Only allow fragments with both reads aligned"
+                    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."/>
 
-            <param name="only_both_ends"
-                   type="boolean"
-                   truevalue=" -B"
-                   falsevalue=""
-                   argument="-B"
-                   label="Only allow fragments with both reads aligned"
-                   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." />
-
-            <param name="exclude_chimerics"
-                type="boolean"
-                truevalue=" -C"
-                falsevalue=""
-                argument="-C"
-                checked="true"
-                label="Exclude chimeric fragments"
-                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." />
-        </section>
+                <param name="exclude_chimerics"
+                    type="boolean"
+                    truevalue=" -C"
+                    falsevalue=""
+                    argument="-C"
+                    checked="true"
+                    label="Exclude chimeric fragments"
+                    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."/>      
+            </when>
+        </conditional>
 
         <section name="read_filtering_parameters" title="Read filtering options">
             <param name="mapping_quality"
                    type="integer"
                    value="0"
+                   min="0"
                    argument="-Q"
                    label="Minimum mapping quality per read"
-                   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." />
+                   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."/>
             <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.">
                 <option value="">No filtering: count split and non-split alignments</option>
                 <option value="--splitOnly">Count only split alignments (--splitOnly)</option>
@@ -278,39 +291,17 @@
                    falsevalue=""
                    argument="--primary"
                    label="Only count primary alignments"
-                   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)." />
+                   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)."/>
             <param name="ignore_dup"
                    type="boolean"
                    truevalue=" --ignoreDup"
                    falsevalue=""
                    argument="--ignoreDup"
                    label="Ignore reads marked as duplicate"
-                   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." />
+                   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."/>
         </section>
 
         <section name="extended_parameters" title="Advanced options">
-            <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." />
-
-            <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." />
-
-            <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." />
-
             <conditional name = "multifeatures">
                 <param name="multifeat" type="select" label="Allow reads to map to multiple features" help="Setting -O, -M and --fraction">
                     <option value="" selected="true">Disabled: reads that align to multiple features or overlapping features are excluded</option>
@@ -320,8 +311,7 @@
                 </param>
                 <when value=""/>
                 <when value="-M">
-                        <param name="fraction"
-                            type="boolean"
+                        <param type="boolean"
                             truevalue="--fraction"
                             falsevalue=""
                             argument="--fraction"
@@ -329,8 +319,7 @@
                             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."/>
                 </when>
                 <when value="-O">
-                        <param name="fraction"
-                            type="boolean"
+                        <param type="boolean"
                             truevalue="--fraction"
                             falsevalue=""
                             argument="--fraction"
@@ -338,8 +327,7 @@
                             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."/>
                 </when>
                 <when value="-O -M">
-                        <param name="fraction"
-                            type="boolean"
+                        <param type="boolean"
                             truevalue="--fraction"
                             falsevalue=""
                             argument="--fraction"
@@ -349,25 +337,25 @@
             </conditional>
 
             <conditional name="exon_exon_junction_read_counting_enabled">
-                <param name="count_exon_exon_junction_reads" argument="-J" type="boolean" truevalue="-J" falsevalue=""
-                       label="Exon-exon junctions"
-                       help="If specified, reads supporting each exon-exon junction will be counted" />
+                <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.">
+                    <option value="-J">Count reads supporting each exon-exon junction.</option>
+                    <option value="" selected="True">Do not count</option>
+                </param>
                 <when value="-J">
                     <param name="genome" argument="-G" type="data" format="fasta" optional="true"
                            label="Reference sequence file"
-                           help="The FASTA-format file that contains the reference sequences used in read mapping can be used to improve read counting for junctions" />
+                           help="The FASTA-format file that contains the reference sequences used in read mapping can be used to improve read counting for junctions"/>
                 </when>
-                <when value="" />
+                <when value=""/>
             </conditional>
 
             <param name="long_reads" argument="-L" type="boolean" truevalue="-L" falsevalue=""
                    label="Long reads"
-                   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." />
+                   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."/>
 
             <param name="by_read_group" argument="--byReadGroup" type="boolean" truevalue="--byReadGroup" falsevalue=""
                   label="Count reads by read group"
-                  help="If specified, reads are counted for each read group separately. The 'RG' tag must be present in the input BAM/SAM alignment files." />
-
+                  help="If specified, reads are counted for each read group separately. The 'RG' tag must be present in the input BAM/SAM alignment files."/>
 
             <param name="largest_overlap"
                    type="boolean"
@@ -375,14 +363,14 @@
                    falsevalue=""
                    argument="--largestOverlap"
                    label="Largest overlap"
-                   help="If specified, reads (or fragments) will be assigned to the target that has the largest number of overlapping bases" />
+                   help="If specified, reads (or fragments) will be assigned to the target that has the largest number of overlapping bases"/>
 
             <param name="min_overlap"
                    type="integer"
                    value="1"
                    argument="--minOverlap"
                    label="Minimum bases of overlap"
-                   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." />
+                   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."/>
 
             <param name="frac_overlap"
                   type="integer"
@@ -391,7 +379,7 @@
                   max="1"
                   argument="--fracOverlap"
                   label="Minimum fraction (of read) overlapping a feature"
-                  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." />
+                  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."/>
 
             <param name="frac_overlap_feature"
                      type="integer"
@@ -400,21 +388,23 @@
                      max="1"
                      argument="--fracOverlapFeature"
                      label="Minimum fraction (of feature) overlapping a read"
-                     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." />
+                     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."/>
 
             <param name="read_extension_5p"
                    type="integer"
                    value="0"
+                   min="0"
                    argument="--readExtension5"
                    label="Read 5' extension"
-                   help="Reads are extended upstream by ... bases from their 5' end" />
+                   help="Reads are extended upstream by ... bases from their 5' end"/>
 
             <param name="read_extension_3p"
                    type="integer"
                    value="0"
+                   min="0"
                    argument="--readExtension3"
                    label="Read 3' extension"
-                   help="Reads are extended upstream by ... bases from their 3' end" />
+                   help="Reads are extended upstream by ... bases from their 3' end"/>
 
             <param name="read_reduction"
                    type="select"
@@ -431,7 +421,7 @@
                    falsevalue=""
                    argument="-R"
                    label="Annotates the alignment file with 'XS:Z:'-tags to described per read or read-pair the corresponding assigned feature(s)."
-                   help="" />
+                   help=""/>
 
         </section>
     </inputs>
@@ -441,7 +431,7 @@
               label="${tool.name} on ${on_string}: Counts (with length)">
             <filter>format == "tabdel_medium"</filter>
             <actions>
-                <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier},Length" />
+                <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier},Length"/>
             </actions>
         </data>
 
@@ -456,7 +446,7 @@
               label="${tool.name} on ${on_string}: Counts">
             <filter>format == "tabdel_short"</filter>
             <actions>
-                <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier}" />
+                <action name="column_names" type="metadata" default="Geneid,${alignment.element_identifier}"/>
             </actions>
         </data>
 
@@ -465,7 +455,7 @@
               label="${tool.name} on ${on_string}: Counts (with location)">
             <filter>format == "tabdel_full"</filter>
             <actions>
-                <action name="column_names" type="metadata" default="Geneid,Chr,Start,End,Strand,Length,${alignment.element_identifier}" />
+                <action name="column_names" type="metadata" default="Geneid,Chr,Start,End,Strand,Length,${alignment.element_identifier}"/>
             </actions>
         </data>
 
@@ -473,7 +463,7 @@
               name="output_summary"
               label="${tool.name} on ${on_string}: Summary">
             <actions>
-                <action name="column_names" type="metadata" default="Status,${alignment.element_identifier}" />
+                <action name="column_names" type="metadata" default="Status,${alignment.element_identifier}"/>
             </actions>
         </data>
 
@@ -482,7 +472,7 @@
               label="${tool.name} on ${on_string}: Feature lengths">
             <filter>include_feature_length_file</filter>
             <actions>
-                <action name="column_names" type="metadata" default="Feature,Length" />
+                <action name="column_names" type="metadata" default="Feature,Length"/>
             </actions>
         </data>
 
@@ -491,16 +481,16 @@
             <filter>extended_parameters['exon_exon_junction_read_counting_enabled']['count_exon_exon_junction_reads']</filter>
             <actions>
                 <action name="column_names" type="metadata"
-                    default="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,${alignment.element_identifier}" />
+                    default="PrimaryGene,SecondaryGene,Site1_chr,Site1_location,Site1_strand,Site2_chr,Site2_location,Site2_strand,${alignment.element_identifier}"/>
             </actions>
         </data>
     </outputs>
     <tests>
         <test expect_num_outputs="3">
-            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" />
+            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
             <param name="anno_select" value="history"/>
-            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" />
-            <param name="format" value="tabdel_medium" />
+            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
+            <param name="format" value="tabdel_medium"/>
             <param name="include_feature_length_file" value="true"/>
             <output name="output_medium" file="output_1_medium.tab">
                 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/>
@@ -510,10 +500,10 @@
             </output>
         </test>
         <test expect_num_outputs="3">
-            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" />
+            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
             <param name="anno_select" value="history"/>
-            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" />
-            <param name="format" value="tabdel_full" />
+            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
+            <param name="format" value="tabdel_full"/>
             <param name="include_feature_length_file" value="true"/>
             <output name="output_full" file="output_1_full.tab">
                 <metadata name="column_names" value="Geneid,Chr,Start,End,Strand,Length,featureCounts_input1.bam"/>
@@ -526,10 +516,10 @@
             </output>
         </test>
         <test expect_num_outputs="4">
-            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" />
+            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
             <param name="anno_select" value="history"/>
-            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38" />
-            <param name="format" value="tabdel_short" />
+            <param name="reference_gene_sets" value="featureCounts_guide.gff" ftype="gff" dbkey="hg38"/>
+            <param name="format" value="tabdel_short"/>
             <param name="include_feature_length_file" value="true"/>
             <param name="count_exon_exon_junction_reads" value="-J"/>
             <output name="output_short" file="output_1_short.tab">
@@ -544,11 +534,14 @@
         </test>
         <!-- Ensure featureCounts built-in annotation works -->
         <test expect_num_outputs="3">
-            <param name="alignment" value="pairend_strandspecific_51mer_hg19_chr1_1-100000.bam" ftype="bam" dbkey="hg19" />
+            <param name="alignment" value="pairend_strandspecific_51mer_hg19_chr1_1-100000.bam" ftype="bam" dbkey="hg19"/>
             <param name="anno_select" value="builtin"/>
-            <param name="format" value="tabdel_short" />
+            <param name="format" value="tabdel_short"/>
+            <conditional name="pe_parameters">
+                <param name="paired_end_status" value="PE_individual"/>
+            </conditional>
             <section name="extended_parameters">
-                <param name="R" value="true" />
+                <param name="R" value="true"/>
             </section>
             <output name="output_short" file="output_builtin_hg19.tab">
                 <metadata name="column_names" value="Geneid,pairend_strandspecific_51mer_hg19_chr1_1-100000.bam"/>
@@ -558,9 +551,9 @@
         </test>
         <!-- Ensure cached GTFs work -->
         <test expect_num_outputs="3">
-            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38" />
+            <param name="alignment" value="featureCounts_input1.bam" ftype="bam" dbkey="hg38"/>
             <param name="anno_select" value="cached"/>
-            <param name="format" value="tabdel_medium" />
+            <param name="format" value="tabdel_medium"/>
             <param name="include_feature_length_file" value="true"/>
             <output name="output_medium" file="output_1_medium.tab">
                 <metadata name="column_names" value="Geneid,featureCounts_input1.bam,Length"/>
@@ -571,11 +564,11 @@
         </test>
         <!-- Ensure BAM output works -->
         <test>
-            <param name="alignment" value="subset.sorted.bam" ftype="bam" />
-            <param name="anno_select" value="history" />
-            <param name="reference_gene_sets" value="small.gtf" ftype="gtf" />
-            <section name="extended_parameters" >
-                <param name="R" value="true" />
+            <param name="alignment" value="subset.sorted.bam" ftype="bam"/>
+            <param name="anno_select" value="history"/>
+            <param name="reference_gene_sets" value="small.gtf" ftype="gtf"/>
+            <section name="extended_parameters">
+                <param name="R" value="true"/>
             </section>
             <output name="output_bam" value="subset.sorted.featurecounts.bam" compare="sim_size"/>
         </test>
@@ -609,8 +602,8 @@
   GeneID  Chr   Start    End      Strand
   ======  ====  =======  =======  ======
   497097  chr1  3204563  3207049  -
-  497097  chr1  3411783  3411982  -
-  497097  chr1  3660633  3661579  -
+  497098  chr1  3411783  3411982  -
+  497099  chr1  3660633  3661579  -
   ======  ====  =======  =======  ======
 
 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.
@@ -627,3 +620,4 @@
         <citation type="doi">10.1093/bioinformatics/btt656</citation>
     </citations>
 </tool>
+