diff subsearch.xml @ 0:98e12cc1f3a8 draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/chemicaltoolbox/openbabel commit 01da22e4184a5a6f6a3dd4631a7b9c31d1b6d502
author bgruening
date Sat, 20 May 2017 08:40:52 -0400
parents
children ab2b9d87b067
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/subsearch.xml	Sat May 20 08:40:52 2017 -0400
@@ -0,0 +1,77 @@
+<tool id="openbabel_subsearch" name="Substructure Search" version="@VERSION@.0">
+    <description>of fingerprint data sets</description>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <expand macro="requirements"/>
+    <command detect_errors="aggressive">
+<![CDATA[
+
+    python '$__tool_directory__/subsearch.py'
+        -i '${query}'
+        --iformat '${query.ext}'
+        --fastsearch-index '${os.path.join($fastsearch.extra_files_path, 'molecule.fs')}'
+        -o '${outfile}'
+        --oformat $oformat
+        --max-candidates $max_candidates
+        --processors "\${GALAXY_SLOTS:-12}"
+
+]]>
+    </command>
+    <inputs>
+        <param name="query" type='data' format="tabular,smi,sdf,inchi,txt" label="query"/>
+        <param name="fastsearch" type='data' format="obfs" label="OpenBabel Fastsearch Index" help="The OpenBabel fastsearch index can be created with the convert tool."/>
+        <param name="max_candidates" type="integer" value="4000" label="The maximum number of candidates"/>
+        <param name='oformat' type='select' format='text' label="Output format.">
+            <option value='smi'>SMILES</option>
+            <option value='inchi'>InChI</option>
+            <option value='sdf'>SD-Files</option>
+            <option value='mol2'>mol2</option>
+            <option value='names'>Return the molecule names only</option>
+        </param>
+    </inputs>
+    <outputs>
+       <data format="smi" name="outfile">
+         <change_format>
+           <when input="oformat" value="inchi" format="inchi"/>
+           <when input="oformat" value="sdf" format="sdf"/>
+           <when input="oformat" value="mol2" format="mol2"/>
+           <when input="oformat" value="names" format="tabular"/>
+         </change_format>
+       </data>
+    </outputs>
+    <tests>
+        <test>
+            <param name="query" ftype="sdf" value="CID_2244.sdf"/>
+            <param name="fastsearch" value="ob_convert_on_CID2244_obfs.txt" ftype="obfs" >
+                <composite_data value='molecule.sdf' ftype="sdf"/>
+                <composite_data value='molecule.fs'/>
+            </param>
+            <param name="oformat" value="names" />
+            <output name="outfile" ftype="tabular" file="ob_subsearch_with_CID2244.tabular" />
+        </test>
+    </tests>
+    <help>
+<![CDATA[
+
+.. class:: infomark
+
+**What this tool does**
+
+Substructure search in based on Open Babel FastSearch_ Index. It uses molecular fingerprints to prepare and search an index of a multi-molecule datafile.
+
+.. _FastSearch: http://openbabel.org/wiki/FastSearch
+
+-----
+
+.. class:: infomark
+
+**Input**
+
+SMILES or SMARTS patterns are possible. SD- and InChI files are converted to SMILES.
+
+
+]]>
+    </help>
+    <expand macro="citations"/>
+</tool>