Hi, On Tue, Apr 2, 2019 at 1:49 AM Phuong Chau <pc...@smith.edu> wrote:
> > Thank you RDKIT. I found this is a very helpful instruction about how to > get all the dihedral restraints of a molecule ( > https://sourceforge.net/p/rdkit/mailman/message/34554502/ ). From the > code provided, I have some questions: > > Since the output is the id of the atom which is different from the id of > the atom in PDB file generated by MolToPDBFile(), how can I determine which > ID number corresponding to which atom exactly? Is it the id number > generated by enumerateTorsions() 1 unit less than the actual id number in > pdb file of same molecule? > Yes, in the PDB file atoms are numbered starting at 1 and the RDKit numbers them starting at 0. So atom ID 3 in the PDB is atom ID 2 in the RDKit. > > As a follow up, is there any possible ways to detect torsion restraints > only on bonds that have Trans geometry when Trans geometry is possible for > that bond ? > > For example: if I input a random chemical with SMILES string as > c2ccc(CCc1ccccc1)cc2 (2 rings connected by CCCC), how should I manipulate > the code so that it only output the ID of the middle parts of the molecule > which is the CCCC (which has possible TRANS conformation)? > The key is to find a way to query that only matches torsions that can adopt a TRANS conformation. This is, no doubt, possible, but I don't have anything convenient for it. One straightforward way to at least somewhat limit the possibilities would be to only pick non-ring single bonds between aliphatic carbon atoms. A possible SMARTS for that would be: In [2]: p = Chem.MolFromSmarts('*C-!@C*') In [3]: Chem.MolFromSmiles('c1ccccc1CCc2ccccc2').GetSubstructMatches(p) Out[3]: ((5, 6, 7, 8),) Best, -greg > > Thank you so much for your help. > > Phuong Chau > Smith College '20 > Engineering and Data Science Major > _______________________________________________ > Rdkit-discuss mailing list > Rdkit-discuss@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rdkit-discuss >
_______________________________________________ Rdkit-discuss mailing list Rdkit-discuss@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rdkit-discuss