I tested your code on several structures and noticed that it failed on
molecules with only one element (NH3, OH2...).
Then I checked
https://www.rdkit.org/docs/source/rdkit.Chem.rdMolTransforms.html and saw
that the default ignores hydrogens. So try
Hello, your question prompted me to write a small notebook, which I hope
you may find useful:
https://github.com/rflameiro/projects/blob/main/comparing_fingerprint_bits.ipynb
In summary, bits that are active in both fingerprints usually correspond to
the same substructure, unless bit collision
Dear all, I remember having used some SMARTS-based function to flag
structures containing "non-organic" atoms. It seems that there is a knime
node for that (
Thank you, all! Here is my Python implementation for anyone interested:
# Check for compounds with "non-organic" atoms
not_organic_pat =
Chem.MolFromSmarts("[!#5;!#6;!#7;!#8;!#16;!#15;!F;!Cl;!Br;!I;!#1]")
# not_organic_pat =
I have never used it, but RDKit has functionality to standardize the
representation, as described here:
https://bitsilla.com/blog/2021/06/standardizing-a-molecule-using-rdkit/. I
couldn't say if either approach is better/worse than the other. With
tautomers, my guess is that you have to either be
However, now that I have visualized the graphs generated, I believe this
was not an optimal solution, since the graphs do not look reduced at all.
Also, the Ac/Ar/D/Hf nomenclature presented on the original ErG paper does
not seem to be implemented in RDKit. For now, I believe it's best to stick
Using rdReducedGraphs.GenerateMolExtendedReducedGraph() on RDKit
mols obtained from certain SMILES
(e.g. "O=C(OC3c1nccnc1C(=O)N3c2ncc(Cl)cc2)N4CCN(C)CC4") throws the
following error:
getNumImplicitHs() called without preceding call to calcImplicitValence()
I tried removing sanitization/keeping
To find all compounds that match the ester substructure, you can use
GetSubstructMatches. I would do the following (I'm supposing you have all
your structures in a Pandas dataframe, and that you converted SMILES to
RDKit Mol):
ester_pattern = Chem.MolFromSmarts("COC(C)=O")
# in a pandas
Hi Carsten
Your code has two problems:
1. [#4] doesn't mean the number of substitutions, [#0] is an indication for
the "non=atom" in SMILES (shown as *)
2. You didn't set the keyword replaceAll to True. Doing this will replace
all matches found.
Therefore, for your code to work properly, replace:
Renato, it seems that FragmentOnBRICSBonds and BRICS.BRICSDecompose work
differently. The first returns a mol object from which you can get the
fragments using GetMolFrags (as you did), while the second returns a list
of strings containing the fragments. I'm not sure if you can recover 3D
info
Hi, I'm just creating this thread to get the problem and the solution
indexed by Google
I downloaded several SDF datasets from BindingDB and got errors like this
one when using Chem.SDMolSupplier:
ERROR: Cannot convert 1. to unsigned int
After some digging I found [
11 matches
Mail list logo