> I can find documentation and examples on reading reactions in one format and 
> saving them to a different one using obabel or language bindings, but I can't 
> find anything for applying a reaction SMARTS to a molecule and obtaining the 
> result.

You want the OBChemTsfm class:
http://openbabel.org/api/2.3/classOpenBabel_1_1OBChemTsfm.shtml

> For example, If I want to convert all carboxyl groups in an input file to 
> chlorides (throwing away the COOH), is that easy to do in obabel or in 
> python?  Is there some examples or documentation on this that I am missing?

I know that OBChemTsfm is available in the Python bindings. You'd take an 
expression like this:

[nD2:1]1c[nH]cc1 >> [n+:1]1c[nH]cc1

I haven't tried this in Python, but you'd do something like this (written in 
C++)

OBChemTsfm   rxn;
rxn.Init("[nD2:1]1c[nH]cc1", "[n+:1]1c[nH]cc1"); 
rxn.Apply(mol);

The bigger problem is building up an open database, but if there are interested 
parties I think a pool of reactions would be very interesting for many uses.

Hope that helps,
-Geoff
------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to