Re: [Rdkit-discuss] m.GetProp('property'): KeyError: 'property'

2016-07-12 Thread Brian Kelley
Markus, In newer versions of RDKit there is a handy method: d = mol.GetPropsAsDict() which returns a python dictionary of all the sd data by default. It also has a nice feature that it converts numeric values to proper python numbers. This can be used as a python dictionary: for prop,value i

Re: [Rdkit-discuss] m.GetProp('property'): KeyError: 'property'

2016-07-12 Thread Paolo Tosco
Dear Markus, you may check if the key exists before trying to retrieve its value with the HasProp() method. Cheers, p. On 12/07/2016 17:10, Markus Metz wrote: Dear all: I spend some time searching the rdkit website and its mailing list. But I was not able to find anything regarding my issu

[Rdkit-discuss] m.GetProp('property'): KeyError: 'property'

2016-07-12 Thread Markus Metz
Dear all: I spend some time searching the rdkit website and its mailing list. But I was not able to find anything regarding my issue. I am a newbie. So bear with me if this is a FAQ. I am trying to extract the properties for molecules from an sd file. This worked fine with the id. But not so for

[Rdkit-discuss] FingerprintMol optional arguments

2016-07-12 Thread Maksymilian Mrozowski
Hi I was trying to use the FingerprintMol function with minSize optional parameter to set all my fingerprints to the same size, but it turned out that all the optional parameters stated earlier in the code need to be given as well, otherwise one gets the following error. Calling this function: >F