Actually, you want to send your loving thoughts to MDL (now: Biovia). They defined the SDF format :-).

Cheers
-- Jan

On 2015-04-29 13:26, Nicholas Firth wrote:
Ahh ok… Interesting way to format a file! Got to love ChemAxon...

Best,
Nick

*Nicholas C. Firth*| PhD Student | Cancer Therapeutics
The Institute of Cancer Research | 15 Cotswold Road | Belmont | Sutton | Surrey | SM2 5NG

*T* 020 8722 4033 |*E*nicholas.fi...@icr.ac.uk <mailto:nicholas.fi...@icr.ac.uk>|*W*www.icr.ac.uk <http://www.icr.ac.uk/>|*Twitter*@ICRnews <https://twitter.com/ICRnews>

*Facebook*www.facebook.com/theinstituteofcancerresearch <http://www.facebook.com/theinstituteofcancerresearch>

*Making the discoveries that defeat cancer*



On 29 Apr 2015, at 12:23, Paolo Tosco <paolo.to...@unito.it <mailto:paolo.to...@unito.it>> wrote:

Hi Nick,

newlines in data properties are fine, but they should not include blank lines (i.e., multiple newlines).
For example, in:

>  <my_property1>
1

2

3

4

>  <my_property2>
1234

>  <my_property3>
5678

my_property1 will be truncated to just "1". Based on the specifications, if you want to include a blank line, it should actually be either a " " or a "\t", rather than being completely blank.

Cheers,
Paolo

On 04/29/15 12:16, Nicholas Firth wrote:
I use SD files with new lines in the properties quite frequently (inherited from Pipeline Pilot's merge function) and I've never had a problem reading them. I've attached an SD file that works fine for me.

In [2]: suppl = Chem.SDMolSupplier('/Volumes/nfirth/tempf.sdf')

In [3]: m = suppl[0]

In [4]: t = m.GetProp('genNum')

In [5]: print t
1
2
3
4

In [6]: print t.split('\n')
['1', '2', '3', '4']


So I guess the problem is in the writer?

Best,
Nick

------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud 
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss

Reply via email to