I read document about RDKit for the first time in a while and found nice snippet.
A 3D Pharmacophore finger print can be caluclated very easily.
from rdkit import Chem, DataStructs, RDConfig from rdkit.Chem import AllChem from rdkit.Chem.Pharm2D import Gobbi_Pharm2D, Generate mol = Chem.MolFromSmiles( 'O=C2C(Cc1ccc(cc1)C(C(=O)O)C)CCC2' ) AllChem.EmbedMolecule( mol ) #gen 3d factory = Gobbi_Pharm2D.factroy #calc 3d p4 fp fp = Generate.Generate2DFingerPrint( mol, factory, dMat = Chem.Get3DDistanceMatrix(mol ) # dMat option is Key!
If dMat = None( default setting), fp means 2D Pharamcophore fingerprint, but now I passed dMat so the fingerprint has 3D information.
Now 3D pharmacophore fingerprint in hand, it means I can try to 3D QSAR or 3D fingerprint based filtering.
I’ll try to do it ASAP. ;-)
Thank you for this post.
I was reading a similar post of rdkit.org and getting confused as they used “Generate.Generate2DFingerPrint”
but “dMat = Chem.Get3DDistanceMatrix(mol )” is the key.
But why don’t you use directly the http://rdkit.org/docs/source/rdkit.Chem.Pharm3D.Pharmacophore.html module?
Is there a way to visualize the common 3d pharmacophore between two compounds?
Thank you for your query. If you want to get pharmacophore, you can use rdkit.Chem.Pharm3D class. What I want to get is pharmacophore fingerprint. Fingerprint generation method is not implemented in Pharm3D class.
You can find same approach in RDKit CookBook.
http://www.rdkit.org/docs/Cookbook.html
”A 3D pharmacophore fingerprint can be calculated using the RDKit by feeding a 3D distance matrix to the 2D-pharmacophore machinery.”
This is because RDKit defines the pharmacophore as SMARTS strings. It does not depend on whether input molecule is 2D or 3D.
Key point is distance matrix, it provides the 3D distance relationships of features.
And if you want to draw pharmacophore in 3D. How about following approach?
https://iwatobipen.wordpress.com/2013/09/16/rdkit-and-pymol/
Is it answer for you?
So if I understand correctly.
A compound will always have the same 2 D pharmacophore fingerprint.
But its 3D pharmacophore fingerprint may be different depending on its conformation.
For example:
Let say two mol objects of the same compound in two different conformations: ,mol_conf2 mol_conf2
fp1 = Generate.Generate2DFingerPrint( mol, factory, dMat = Chem.Get3DDistanceMatrix(mol_conf1)
fp2 = Generate.Generate2DFingerPrint( mol, factory, dMat = Chem.Get3DDistanceMatrix(mol_conf2)
so fp1 is different from fp2. Right?
And the last question: Is there a way to visualize the common 3d pharmacophore between two compounds?
That’s right, 3D pharmacophore depends not only structure but also its conformation.
And if you want to visualize pharmacophores in rdkit, I think you can do it by using Chem.Features module. But I never try it.
Thank you
Thank you for sharing your scripts. They are very useful. Have you ever tried to cluster a set of compounds based on 3D pharmacophore fingerprints? Thank you!
Hi thanks for your comment:-) I have not tried yet. But it sounds interesting.