Well, as I said, I really only want to preserve the mapping of the order of the atoms as they appear in SDF and atoms as they appear in the canonical smiles string. It would seem that using the output options I specified, as a post-conversion step I could simply look for the order of the atoms having the indicated combination of the reported X and Y coordinates.
For some reason, the -xx option does not output the Z coordinate even though the coordinate is non-zero in my input. Would it be easy for someone to change that, so that Z-coordinate is printed? Because if my original molecule is planar (e.g. benzene) and is aligned in the xz plane, the X and Y coordinates may not identify the benzene ring atoms uniquely, and the process I've just outlined won't work. Of course, it would beeven better if someone actually added an option in -x such that the actual original atom positions were reported instead of the X and Y coordinates. Thank you so much, Geoff! On Sun, Feb 21, 2010 at 7:37 AM, Geoffrey Hutchison <ge...@geoffhutchison.net> wrote: >> babel -isdf yournoncanonicalsdf.sdf -osmi yoursmilesfile.smi -xcx >> >> The -xc part should output canonical smiles, and -xx gives me the >> X-coordinate of the atoms in the order they appear in the canonical >> SMILES string. Is this usage safe/correct? Is the canonicalization >> algorithm in -osmi -xc the same as in -ocan ? Because if that's the >> case, no extra work needs to be done. > > If all you want is the XYZ coordinates, then you can certainly use that > method. There is no difference between using "-xc" to indicate that you want > canonical SMILES and using the so-called "can" format. There's just more than > one way to do it. > > Hope that helps, > -Geoff ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ OpenBabel-discuss mailing list OpenBabel-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-discuss