Hi RDKitters, I'm sure this must of been covered somewhere else but I can't find it in the forum or the source.
I am manipulating SMILES strings and wonder whether I can use RDKit as a
shortcut, so my question is does the order of occurrence in a SMILES string of
an atom match the atom index that is given by RDKit. It seems to me that it
does but I'd like to know for all cases. For example
>>> from rdkit import Chem
>>> mol=Chem.MolFromSmiles('CSNOC')
>>> for atom in mol.GetAtoms(): print atom.GetAtomicNum(),atom.GetIdx()
...
6 0
16 1
7 2
8 3
6 4
This is what I would expect, but is there a case when this order might not be
conserved?
If the order isn't always conserved, how does the indexing cope with RDKit
canonical smiles?
Thanks in advance.
Best,
Nick
Nicholas C. Firth | PhD Student | Cancer Therapeutics
The Institute of Cancer Research | 15 Cotswold Road | Belmont | Sutton | Surrey
| SM2 5NG
T 020 8722 4033 | E [email protected]<mailto:[email protected]> |
W www.icr.ac.uk<http://www.icr.ac.uk/> | Twitter
@ICRnews<https://twitter.com/ICRnews>
Facebook
www.facebook.com/theinstituteofcancerresearch<http://www.facebook.com/theinstituteofcancerresearch>
Making the discoveries that defeat cancer
[cid:[email protected]]
The Institute of Cancer Research: Royal Cancer Hospital, a charitable Company
Limited by Guarantee, Registered in England under Company No. 534147 with its
Registered Office at 123 Old Brompton Road, London SW7 3RP.
This e-mail message is confidential and for use by the addressee only. If the
message is received by anyone other than the addressee, please return the
message to the sender by replying to it and then delete the message from your
computer and network.<<inline: image001.gif>>
------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar
_______________________________________________ Rdkit-discuss mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

