# HG changeset patch # User devteam # Date 1447263226 18000 # Node ID 2098a49ddf664a07a1c7661895ce40a274eddf39 # Parent d64c7e752f4dd578345faf0a6b02d3dd8937a96b planemo upload for repository https://github.com/galaxyproject/tools-devteam/tree/master/tool_collections/bamtools/bamtools_filter commit a1517c9d22029095120643bbe2c8fa53754dd2b7 diff -r d64c7e752f4d -r 2098a49ddf66 bamtools-filter.xml --- a/bamtools-filter.xml Mon Mar 09 14:07:23 2015 -0400 +++ b/bamtools-filter.xml Wed Nov 11 12:33:46 2015 -0500 @@ -1,32 +1,27 @@ - + BAM datasets on a variety of attributes bamtools + cat $script_file > $out_file2; - cat $script_file > $out_file2; - #for $bam_count, $input_bam in enumerate( $input_bams ): - ln -s "${input_bam.input_bam}" "localbam_${bam_count}.bam" && - ln -s "${input_bam.input_bam.metadata.bam_index}" "localbam_${bam_count}.bam.bai" && + ln -s "${input_bam}" "localbam_${bam_count}.bam" && + ln -s "${input_bam.metadata.bam_index}" "localbam_${bam_count}.bam.bai" && #end for - + bamtools filter -script $script_file - + #for $bam_count, $input_bam in enumerate( $input_bams ): -in "localbam_${bam_count}.bam" #end for -out $out_file1 - - - - - + @@ -59,10 +54,10 @@ - + - + @@ -164,7 +159,7 @@ - + @@ -185,20 +180,20 @@ #for $i, $c in enumerate( $conditions, start=1 ) { "id": "$i", #for $j, $s in enumerate( $c.filters, start=1 ) - ##The if below takes care of the comma at the end of last condition within group + ##The if below takes care of the comma at the end of last condition within group #if $j != len( $c.filters) "${s.bam_property.bam_property_selector}":"${s.bam_property.bam_property_value}", #else "${s.bam_property.bam_property_selector}":"${s.bam_property.bam_property_value}" #end if #end for - ##The if below takes care of the comma at the end of last condition within group + ##The if below takes care of the comma at the end of last condition within group #if $i != len( $conditions ) }, #else } - #end if - #end for + #end if + #end for #if len( $conditions ) > 1 #if str( $rule_configuration.rules_selector ) == "True": ], @@ -217,10 +212,10 @@ - + - + @@ -249,7 +244,7 @@ When filtering on a single condition there is no need to worry about filters and conditions. Just choose a filter from the **Select BAM property to filter on:** dropdown and enter a value (or click a checkbox for binary filters). For example, for retaining reads with mapping quality of at least 20 one would set the tool interface as shown below: -.. image:: ${static_path}/images/single-filter.png +.. image:: single-filter.png ----- @@ -258,7 +253,7 @@ Now suppose one needs to extract reads that (1) have mapping quality of at least 20, (2) contain at least 1 mismatch, and (3) are mapping onto forward strand only. To do so we will use three filters as shown below (multiple filters are added to the interface by clicking on the **Add new Filter** button): -.. image:: ${static_path}/images/multiple-filters.png +.. image:: multiple-filters.png In this case (you can see that the three filters are grouped within a single Condition - **Condition 1**) the filter too use logical **AND** to perform filtering. In other words only reads that (1) have mapping quality of at least 20 **AND** (2) contain at least 1 mismatch **AND** are mapping onto forward strand will be returned in this example. @@ -267,11 +262,11 @@ **Example 3. Complex filtering with multiple conditions** -Suppose now you would like to select **either** reads that (**1**) have (*1.1*) no mismatches and (*1.2*) are on the forward strand **OR** (**2**) reads that have (*2.1*) -at least one mismatch and (*2.2*) are on the reverse strand. In this scenario we have to set up two conditions: (**1**) and (**2**) each with two filters: *1.1* and *1.2* as well as *2.1* and *2.2*. +Suppose now you would like to select **either** reads that (**1**) have (*1.1*) no mismatches and (*1.2*) are on the forward strand **OR** (**2**) reads that have (*2.1*) +at least one mismatch and (*2.2*) are on the reverse strand. In this scenario we have to set up two conditions: (**1**) and (**2**) each with two filters: *1.1* and *1.2* as well as *2.1* and *2.2*. The following screenshot expalins how this can be done: -.. image:: ${static_path}/images/complex-filters.png +.. image:: complex-filters.png ----- @@ -282,10 +277,10 @@ filtering will look like this:: !(1) & (2 | 3) - + Here, numbers 1, 2, and 3 represent conditions. The following screenshot illustrates how to do this in Galaxy: -.. image:: ${static_path}/images/rule.png +.. image:: rule.png There are three conditions here, each with a single filter. A text entry area that can be opened by clicking on the **Would you like to set rules?** checkbox enables you to enter a rule. Here numbers correspond to numbers of conditions as they are shown in the interface. E.g., 1 corresponds to condition 1, 2 to condition 2 and so on... In human language this means:: @@ -312,8 +307,7 @@ } ] } - - + ----- diff -r d64c7e752f4d -r 2098a49ddf66 tool_dependencies.xml --- a/tool_dependencies.xml Mon Mar 09 14:07:23 2015 -0400 +++ b/tool_dependencies.xml Wed Nov 11 12:33:46 2015 -0500 @@ -1,6 +1,6 @@ - +