Not tested

# script RD_descript.py
print "Hello from RD_descript "

from cinfony import rdk
from rdkit import Chem
from rdkit.Chem import AvailDescriptors

for d in AvailDescriptors.descDict:
   print d


suppl = open("Nom file","r")
w = Chem.SDWriter("SDF File")
numRead = 0
numStructures = 0
for m in suppl:
   numRead += 1
   if m != None:
      numStructures += 1
      smi = Chem.MolToSmiles(m.strip())
      m.SetProp("SMILES",smi)
      print smi
      for d in AvailDescriptors.descDict:
#      print d
         pr = AvailDescriptors.descDict[d]( m.strip())
#      print str(pr)
         m.SetProp(d,str(pr))
      w.write(m)

print "nombre initiale = " + str(numRead )
print "nombre finale = " + str(numStructures)

From: Damjan Krstajic [mailto:[email protected]]
Sent: mercredi, 2. juin 2010 11:21
To: [email protected]
Subject: [Rdkit-discuss] RDKit descriptors batch

Hello,

I would like to use RDKit to calculate descriptors. I am interested in a batch 
program which would calculate the RDKit descriptors from a smiles file (.smi). 
I don't have any experience with Python. Do you have any advice on how to 
create the batch program? I am prepared to code it and give it to you so that 
others can use it.

Thanks
DK
________________________________
Get a new e-mail account with Hotmail - Free. Sign-up 
now.<http://clk.atdmt.com/UKM/go/197222280/direct/01/>

**********************************************************************
DISCLAIMER
This email and any files transmitted with it, including replies and forwarded 
copies (which may contain alterations) subsequently transmitted from Firmenich, 
are confidential and solely for the use of the intended recipient. The contents 
do not represent the opinion of Firmenich except to the extent that it relates 
to their official business.
**********************************************************************

------------------------------------------------------------------------------

_______________________________________________
Rdkit-discuss mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to