diff sucos_max.xml @ 5:d4c67ced6abc draft

"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/chemicaltoolbox/sucos commit c35334ca80c87a5078da1a6df85b34e23b80d837"
author bgruening
date Wed, 15 Apr 2020 09:26:07 -0400
parents 85fad59f8168
children 55ac04db36aa
line wrap: on
line diff
--- a/sucos_max.xml	Mon Apr 06 09:12:07 2020 -0400
+++ b/sucos_max.xml	Wed Apr 15 09:26:07 2020 -0400
@@ -1,4 +1,4 @@
-<tool id="sucos_max_score" name="Max SuCOS score" version="0.2.2">
+<tool id="sucos_max_score" name="Max SuCOS score" version="0.2.3">
     <description>- determine maximum SuCOS score of ligands against clustered fragment hits</description>
     <macros>
         <import>sucos_macros.xml</import>
@@ -8,6 +8,9 @@
         python '$__tool_directory__/sucos_max.py'
             -i '$input'
             -o '$output'
+        #if $filter_field and $filter_value
+            --filter-field '$filter_field' --filter-value $filter_value
+        #end if
         #for $cluster in $clusters
             '$cluster'
         #end for
@@ -15,6 +18,17 @@
     <inputs>
         <param name="input" type="data" format="sdf" label="Ligands to be scored" help="Input in SDF format." />
         <param name="clusters" type="data" format="sdf" multiple="true" label="Set of clusters to score against" help="Clusters in SDF format." />
+        <param name="filter_field" type="text" label="Filter field" optional="true"
+               help="Filter output using this field's values. (e.g. Max_SuCOS_Score or Cum_SuCOS_Score)">
+            <sanitizer>
+                <valid initial="string.printable">
+                    <remove value="&apos;"/>
+                </valid>
+                <mapping initial="none"/>
+            </sanitizer>
+        </param>
+        <param name="filter_value" type="float" label="Filter value" optional="true"
+               help="Filter out scores less than this value."/>
     </inputs>
     <outputs>
         <data format="sdf" name="output" label="The scored ligands"/>
@@ -27,6 +41,20 @@
                 <assert_contents>
                     <has_text text="Max_SuCOS_Score" />
                     <has_text text="Cum_SuCOS_Score" />
+                    <has_n_lines n="2224" />
+                </assert_contents>
+            </output>
+        </test>
+        <test>
+            <param name="input" ftype="sdf" value="sucos_cluster.sdf"/>
+            <param name="clusters" ftype="sdf" value="cluster1.sdf,cluster2.sdf,cluster3.sdf,cluster4.sdf,cluster5.sdf,cluster6.sdf"/>
+            <param name="filter_field" value="Cum_SuCOS_Score"/>
+            <param name="filter_value" value="15"/>
+            <output name="output" ftype="sdf">
+                <assert_contents>
+                    <has_text text="Max_SuCOS_Score" />
+                    <has_text text="Cum_SuCOS_Score" />
+                    <has_n_lines n="686" />
                 </assert_contents>
             </output>
         </test>
@@ -54,6 +82,10 @@
 The clustered reference compounds are likely to have been generated using the "Cluster ligands using SuCOS" tool and
 will comprise a SDF format file for each cluster. The ligands to be scored are supplied in a SDF file.
 
+Optional filtering of the output is possible, for instance to retain only records with SuCOS scores greater that a
+certain value. Use the optional 'Filter field' and 'Filter value' parameters. The 'Filter field' would typically
+be one of the properties listed below.
+
 .. class:: infomark
 
 **Output**