rdkit

Indexing of strings (molecule SMILES)

Indexing of strings (molecule SMILES) Question: Also, please can someone adjust or give me advice on how to look at the second order of parenthesis. Same process as this, but with only parenthesis in second order (this code is first order). Can you make it so I can easily adjust? By second order I mean …

Total answers: 2

Indexing of strings

Indexing of strings Question: I am trying to get an output based on this procedure, which is best to explain with an example. for example in a smile, C(N)(N)CC(N)C, [0, 1, 2, 0, 0, 1, 0] this is the output I am trying to get. It counts the branching (which is represented by brackets). So …

Total answers: 2

Iterations not storing the correct value

Iterations not storing the correct value Question: I am making a row vector that contains valency and bond information, an multiplying it by an adjacency matrix to make a valency connectivity matrix, however I am having issues with my code. My issue is quite strange with this code. It works for most atoms, but has …

Total answers: 2

Converting an Isometric SMILE into its atoms and non-hydrogen neighbours

Converting an Isometric SMILE into its atoms and non-hydrogen neighbours Question: Hope whoever is reading this is well. I have an issue with my code. I am trying to convert an isometric SMILE, a descriptor of a molecule, into its atomic groups and neightbours. My code is below. import rdkit from rdkit import Chem def …

Total answers: 1

What is the difference between passing the statement Chem.MolFromSmiles directly or via a variable?

What is the difference between passing the statement Chem.MolFromSmiles directly or via a variable? Question: If I do not store the rdkit.Chem.rdchem.Mol object in a variable but pass the statement Chem.MolFromSmiles("<your-smile>") directly into another function it gives a different result than storing it in a variable before! Why is that? >>> from rdkit.Chem import Descriptors …

Total answers: 1

rdkit module functions in Chem.Descriptors not working and unsure why?

rdkit module functions in Chem.Descriptors not working and unsure why? Question: I’m new to using rdkit but can’t find any forum posts online addressing this but I’ve been trying to use the functions in rdkit.Chem.Descriptors as follows: from rdkit import Chem mol = Chem.MolFromSmiles(‘CC’) Descriptors.MolWt(mol) this should just return the molecular weight = 30.07 of …

Total answers: 1

Installing RDKit in Google Colab

Installing RDKit in Google Colab Question: I cannot figure out how to fix the following issue. Up until today I was using the following code snippet for installing RDKit in Google Colab: !wget -c https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh !chmod +x Miniconda3-latest-Linux-x86_64.sh !time bash ./Miniconda3-latest-Linux-x86_64.sh -b -f -p /usr/local !time conda install -q -y -c conda-forge rdkit import sys …

Total answers: 4

how do I install a specific version of the rdkit library for Python2?

how do I install a specific version of the rdkit library for Python2? Question: I need to install a version of the rdkit library released prior to 2019, when support for Python 2 was removed. This is needed to work with this library: https://github.com/brain-research/deep-molecular-massspec I have downloaded the library from the git page, eg. https://github.com/rdkit/rdkit/releases/tag/Release_2018_09_1, …

Total answers: 5

How to generate a graph from a SMILES molecule representation?

How to generate a graph from a SMILES molecule representation? Question: I have a dataset of molecules represented with SMILES strings. I was trying to represent this as graphs. Is there a way to do so? For instance, let’s say I have string CC(C)(C)c1ccc2occ(CC(=O)Nc3ccccc3F)c2c1, is there a general way to convert this to a graph …

Total answers: 4