SMILES conversion

User 8cbba88c0e

21-07-2010 11:48:37

  Hi,



 During the process of loading compounds into our database from sdf files we convert the standardized molecules to smiles format. We have noticed a problem occurs before we standardize though when the molecules have stereocenters where the stereo bonds have been drawn incorrectly. This issue can be flagged in Marvin and the Structure Checker correctly recognizes that the wedge bonds are invalid and corrects them properly. However when we use molecule.toFormat("cxsmiles:-leu"), the invalid stereo bonds are removed and we obtain a smiles with no stereo centers and importing into Marvin gives us a flat molecule. If we use molecule.toFormat("mol") and import the result into Marvin, the invalid stereo centers are preserved and can be corrected. I have attached an sdf file with some example compounds where we have this issue.




There is no warning given that stereo chemical information is being lost during the molecule to smiles conversion. Is there are way to get notified that this is occurring so that we could trap the errors rather than loading the incorrect smiles strings and then having to track these molecules down for correction? 



final MolImporter molImporter = new MolImporter(new FileInputStream(getSdFile()));


 Molecule molecule;


while ((molecule = molImporter.read()) != null) {


 LOGGER.debug("After reading " + molecule.toFormat("mol")); //stereochem kept


LOGGER.debug("After reading " + molecule.toFormat(ChemUtils.SMILES_FORMAT)); //stereochem lost


Thanks


Cheers


Bob




 



ChemAxon 25dcd765a3

21-07-2010 12:56:57

Hi,



There
is no warning given that stereo chemical information is being lost
during the molecule to smiles conversion. Is there are way to get
notified that this is occurring so that we could trap the errors rather
than loading the incorrect smiles strings and then having to track
these molecules down for correction?




Actually there are no stereo chemical information at the attached molecules as the wedges are drawn to such atoms which cannot be stereo center. So it is not possible to drop warning message in this case.


Andras

ChemAxon a3d59b832c

04-08-2010 13:22:08

Bob,


How about using structure checkers API?


That could notify you about the errors, and even fix them, too.


 


BR,


Szabolcs

User 8cbba88c0e

04-08-2010 14:28:29

Hi Szabolcs,


Yes, I think that would be the best option for us as we could fix several of the other annoying errors we encounter as well with the Structure Checker API.


Thanks for your help


Cheers


Bob