Mercurial > repos > bgruening > rdock_rbdock
diff rbdock.xml @ 4:a428230b38f6 draft
"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/chemicaltoolbox/rdock commit db567a29443284f2cec1444ec9db9aa6bd913fad"
author | bgruening |
---|---|
date | Fri, 03 Apr 2020 13:32:13 -0400 |
parents | bad150d12198 |
children | 07fa39ed62c7 |
line wrap: on
line diff
--- a/rbdock.xml Tue Mar 17 09:26:29 2020 -0400 +++ b/rbdock.xml Fri Apr 03 13:32:13 2020 -0400 @@ -1,4 +1,4 @@ -<tool id="rdock_rbdock" name="rDock docking" version="0.1.2"> +<tool id="rdock_rbdock" name="rDock docking" version="0.1.3" profile="19.01"> <description>- perform protein-ligand docking with rDock</description> <macros> <import>rdock_macros.xml</import> @@ -13,15 +13,30 @@ #else ln -s '$ligands' ligands.sdf && #end if -rbdock -i ligands.sdf -r receptor.prm -p dock.prm -n $num -o output && -sdsort -n -s -fSCORE output.sd | -#if $score: - sdfilter -f'\$SCORE <= $score' | + +python '$__tool_directory__/rbdock.py' + -n '$num' + #if $seed: + -s '$seed' + #end if + && + +cat rdock_output.sd + +#if $filter.filter_select == "filter": + #if $filter.score: + | sdfilter -f'\$SCORE <= ${filter.score}' + #end if + #if $filter.nscore: + | sdfilter -f'\$SCORE.norm <= ${filter.nscore}' + #end if + #if $filter.top + | sdsort -n -s -fSCORE | sdfilter -f'\$_COUNT <= $filter.top' + #end if #end if -#if $nscore: - sdfilter -f'\$SCORE.norm <= $nscore' | -#end if -sdfilter -f'\$_COUNT <= $top' > '$output' + + > '$output' + ]]></command> <configfiles> @@ -36,28 +51,57 @@ <param type="data" name="active_site" format="rdock_as" label="Active site" help="Active site file"/> <param type="data" name="ligands" format="sdf,mol" label="Ligands" help="Ligands in SDF format (or single ligand in MOL format)"/> <param name="num" type="integer" value="10" label="Number of dockings" help="Number of poses to generate"/> - <param name="top" type="integer" value="1" label="Number of best poses" help="Number of best scoring poses to keep"/> - <param name="score" type="float" optional="true" label="Score filter" - help="Exclude poses with score greater than this value"/> - <param name="nscore" type="float" optional="true" label="Normalised score filter" - help="Exclude poses with normalised score greater than this value"/> + <conditional name="filter"> + <param name="filter_select" type="select" label="Filter the docking results" help="Using sdfilter"> + <option value="filter">Show filter options</option> + <option value="no_filter">No filtering</option> + </param> + <when value="filter"> + <param name="score" type="float" optional="true" label="Score filter" + help="Exclude poses with score greater than this value"/> + <param name="nscore" type="float" optional="true" label="Normalised score filter" + help="Exclude poses with normalised score greater than this value"/> + <param name="top" type="integer" value="1" optional="true" min="1" label="Number of best poses" + help="Number of best scoring poses to keep"/> + </when> + <when value="no_filter"/> + </conditional> <param name="name" type="boolean" label="Generate name field" truevalue="Y" falsevalue="N" checked="false" help="Generate the name field (first line) for cases where this is empty"/> + <param argument="-seed" type="integer" optional="true" label="Random seed" help=""/> </inputs> <outputs> <data name="output" format="sdf" label="rDock on ${on_string}"/> </outputs> <tests> + <!-- broken ligand test --> + <test expect_failure="true" expect_exit_code="23"> + <param name="receptor" value="receptor.mol2"/> + <param name="ligands" value="broken_ligand.sdf"/> + <param name="active_site" value="receptor.as"/> + <param name="num" value="3"/> + <param name="seed" value="3"/> + <conditional name="filter"> + <param name="filter_select" value="filter"/> + <param name="top" value="1"/> + </conditional> + <param name="name" value="false"/> + </test> <test> <param name="receptor" value="receptor.mol2"/> <param name="ligands" value="ligands_names.sdf"/> <param name="active_site" value="receptor.as"/> <param name="num" value="3"/> - <param name="top" value="1"/> + <param name="seed" value="3"/> + <conditional name="filter"> + <param name="filter_select" value="filter"/> + <param name="top" value="1"/> + </conditional> <param name="name" value="false"/> <output name="output"> <assert_contents> <has_text text="Rbt.Current_Directory"/> + <has_n_lines n="352"/> </assert_contents> </output> </test> @@ -66,11 +110,34 @@ <param name="ligands" value="ligands_nonames.sdf"/> <param name="active_site" value="receptor.as"/> <param name="num" value="3"/> - <param name="top" value="1"/> + <param name="seed" value="3"/> + <conditional name="filter"> + <param name="filter_select" value="filter"/> + <param name="top" value="1"/> + </conditional> <param name="name" value="true"/> <output name="output"> <assert_contents> <has_text text="Rbt.Current_Directory"/> + <has_n_lines n="352"/> + </assert_contents> + </output> + </test> + <!-- no filter test --> + <test> + <param name="receptor" value="receptor.mol2"/> + <param name="ligands" value="ligands_nonames.sdf"/> + <param name="active_site" value="receptor.as"/> + <param name="num" value="3"/> + <param name="seed" value="3"/> + <conditional name="filter"> + <param name="filter_select" value="no_filter"/> + </conditional> + <param name="name" value="true"/> + <output name="output"> + <assert_contents> + <has_text text="Rbt.Current_Directory"/> + <has_n_lines n="1056"/> </assert_contents> </output> </test> @@ -79,12 +146,17 @@ <param name="ligands" value="ligands_names.sdf"/> <param name="active_site" value="receptor.as"/> <param name="num" value="1"/> - <param name="score" value="10"/> - <param name="nscore" value="1"/> - <param name="name" value="false"/> + <param name="seed" value="3"/> + <conditional name="filter"> + <param name="filter_select" value="filter"/> + <param name="score" value="10"/> + <param name="nscore" value="1"/> + </conditional> + <param name="name"/> <output name="output"> <assert_contents> <has_text text="Rbt.Current_Directory"/> + <has_n_lines n="352"/> </assert_contents> </output> </test>