changeset 5:c410ffcabf9d draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/chemicaltoolbox/autodock_vina commit ed9b6859de648aa5f7cde483732f5df20aaff90e
author bgruening
date Tue, 07 May 2019 13:31:43 -0400
parents 3c8e86318a81
children 0ae768a0e5c0
files docking.xml
diffstat 1 files changed, 83 insertions(+), 29 deletions(-) [+]
line wrap: on
line diff
--- a/docking.xml	Mon Feb 12 04:23:13 2018 -0500
+++ b/docking.xml	Tue May 07 13:31:43 2019 -0400
@@ -1,5 +1,5 @@
-<tool id="docking" name="Docking" version="0.1.0">
-    <description>Tool to running molecular docking with Autodock Vina</description>
+<tool id="docking" name="Docking" version="0.2.0">
+    <description>tool to perform protein-ligand docking with Autodock Vina</description>
     <requirements>
         <requirement type="package" version="1.1.2">autodock-vina</requirement>
     </requirements>
@@ -7,12 +7,66 @@
         <exit_code range="1" />
     </stdio>
     <command><![CDATA[
-        vina --config "$box" --receptor "$receptor" --ligand "$ligand" --out "$file_output1" --log "$file_output2"
+        #if $config_params.config_params == 'vals':
+            vina
+                --center_x '$config_params.center_x' 
+                --center_y '$config_params.center_y' 
+                --center_z '$config_params.center_z' 
+                --size_x '$config_params.size_x' 
+                --size_y '$config_params.size_y' 
+                --size_z '$config_params.size_z' 
+                --exhaustiveness '$config_params.exh' 
+                --num_modes 9999 
+                --energy_range 9999 
+                --receptor '$receptor' 
+                --ligand '$ligand' 
+                --out '$file_output1' 
+                --log '$file_output2' 
+                --cpu \${GALAXY_SLOTS:-1}
+                #if $config_params.seed.seed == 'true':
+                    --seed '$config_params.seed.seed_value'
+                #end if
+        #end if
+        #if $config_params.config_params == 'file':
+            vina 
+                --config '$config_params.box' 
+                --receptor '$receptor' 
+                --ligand '$ligand' 
+                --out '$file_output1' 
+                --log '$file_output2' 
+                --cpu \${GALAXY_SLOTS:-1}
+
+        #end if
+        
     ]]></command>
     <inputs>
-        <param type="data" name="box" format="txt" label="Box configuration" help="Select a text file with the box configurations" />
-        <param type="data" name="receptor" format="pdbqt" label="Receptor" help="Select a receptor PDBQT format. This can be prepared using the receptor preparation tool." />
-        <param type="data" name="ligand" format="pdbqt"  label="Ligand" help="Select a ligand PDBQT format. This can be prepared using the ligand preparation tool." />
+        <param type="data" name="receptor" format="pdbqt" label="Receptor" help="Select a receptor (PDBQT format). This can be prepared using the receptor preparation tool." />
+        <param type="data" name="ligand" format="pdbqt"  label="Ligand" help="Select a ligand (PDBQT format). This can be prepared using the ligand preparation tool." />
+        <conditional name="config_params">
+            <param name="config_params" type="select" label="Specify parameters">
+                <option value="file">Upload a config file to specify parameters</option>
+                <option value="vals">Specify values directly</option>
+            </param>
+            <when value="vals">
+                <param type="float" name="center_x" label="x coordinate" help="x coordinate of the binding site." value="0"/>
+                <param type="float" name="center_y" label="y coordinate" help="y coordinate of the binding site." value="0"/>
+                <param type="float" name="center_z" label="z coordinate" help="z coordinate of the binding site." value="0"/>
+                <param type="float" name="size_x" label="x size" help="Length of the binding site (Å) in the x direction." value="0"/>
+                <param type="float" name="size_y" label="y size" help="Length of the binding site (Å) in the y direction." value="0"/>
+                <param type="float" name="size_z" label="z size" help="Length of the binding site (Å) in the z direction." value="0"/>
+                <param type="integer" name="exh" label="Exhaustiveness" help="The number of poses to return from the docking job" value="10"/>
+                <conditional name="seed">
+                    <param name="seed" type="boolean" label="Specify random seed for simulation reproducibility?"/>
+                    <when value="true">
+                        <param type="integer" name="seed_value" label="Random seed" help="Choose a seed value" value="1"/>
+                    </when>
+                    <when value="false"/>
+                </conditional>
+            </when>
+            <when value="file">
+                <param type="data" name="box" format="txt" label="Box configuration" help="Text file with the box configurations" />
+            </when>
+        </conditional>
     </inputs>
     <outputs>
         <data name="file_output1" format="pdbqt" />
@@ -20,43 +74,43 @@
     </outputs>
     <tests>
         <test>
-            <param name="box" value="config_complexo_dm.txt"/>
             <param name="receptor" value="3u1i_for_DM.pdbqt"/>
             <param name="ligand" value="NuBBE_1_obabel_3D.pdbqt"/>
+            <param name="config_params" value="vals"/>
+            <param name="center_x" value="70.92" />
+            <param name="center_y" value="70.57" />
+            <param name="center_z" value="36.86" />
+            <param name="size_x" value="20.00"  />
+            <param name="size_y" value="18.40" />
+            <param name="size_z" value="23.60" />
+            <param name="seed" value="true" />
+            <param name="seed_value" value="1" />
+            <param name="exhaustivenesss" value="10" />
+            <output name="file_output1" file="NuBBE_1_obabel_3D_-_3u1i_for_DM.pdbqt"/>
+            <output name="file_output2" file="NuBBE_1_obabel_3D_-_3u1i_for_DM.log"/>
+        </test>
+        <test>
+            <param name="receptor" value="3u1i_for_DM.pdbqt"/>
+            <param name="ligand" value="NuBBE_1_obabel_3D.pdbqt"/>
+            <param name="config_params" value="file"/>
+            <param name="box" value="config_complexo_dm.txt"/>
             <output name="file_output1" file="NuBBE_1_obabel_3D_-_3u1i_for_DM.pdbqt"/>
             <output name="file_output2" file="NuBBE_1_obabel_3D_-_3u1i_for_DM.log"/>
         </test>
     </tests>
     <help><![CDATA[
-**What it does?**
 
-This tool performs molecular docking with Autodock Vina program.
+This tool performs protein-ligand docking using the Autodock Vina program.
 
 **Inputs**
 
-Three inputs are required for use this tools. The first is a text file with the box configurations, this file looks like the following example::
+The first two inputs required are files (in the pdbqt format) describing the receptor and ligand respectively. These files are produced by the receptor and ligand preparation tools.
 
-    size_x =  20.00
-    size_y =  18.40
-    size_z =  23.60
-    center_x =  70.92
-    center_y =  70.57
-    center_z =  36.86
-    num_modes = 9999
-    energy_range = 9999
-    exhaustiveness = 10
-    cpu = 4
-    seed = 1
-
-Where the parameters size_x, size_y, size_z, center_x, center_y and center_z  are coordinates of the binding site. 
-The parameters num_modes, energy_range, exhaustiveness, cpu and seed are autodock vina configurations to execute the algorithm.
-
-The second input is a receptor file (pdbqt) what is a output of the prepare receptor tool.
-The last input is a ligand file (pdbqt) what is a output of the prepare ligand tool.
+In addition, parameters for docking must be defined. The Cartesian coordinates of the center of the binding site should be provided, along with the size of the binding site along each dimension. Effectively, this defines a cuboidal volume in which docking is performed. Alternatively, a config file can be uploaded containing this information - such a file can be generated from the box parameter calculation file. 
 
 **Outputs**
 
-Two outputs are generated by this tool. The first is a pdbqt file with the molecule structure resulting of the molecular docking, this file looks like the following example::
+Two outputs are generated by this tool. The first is another pdbqt file containing the molecular structure resulting from docking, such as the following example::
 
     MODEL 1
     REMARK VINA RESULT:      -0.0      0.000      0.000
@@ -117,7 +171,7 @@
     TORSDOF 9
     ENDMDL 
 
-The last is a log file with the binding affinity scores, this file looks like the following example::
+The second output is a log file containing the binding affinity scores, like the following::
 
     -----------------------------------------------------------------
      If you used AutoDock Vina in your work, please cite: