I have a library of ~1000 compounds as SMILES strings with an appended name
code and a property. For example:

c1ccc(c2ccccc2)cc1    0001    -2.52

Where "0001" is the name code and "-2.52" is a physicochemical property of
the molecule.

I would like to convert these strings to a concatenated SDF file, where
each entry would be akin to the following:
=====
0001
 OpenBabel02272214483D

 22 23  0  0  0  0  0  0  0  0999 V2000
    1.4317   -0.2725    0.0379 C   0  0  0  0  0  0  0  0  0  0  0  0
    0.5308   -1.3294   -0.0416 C   0  0  0  0  0  0  0  0  0  0  0  0
   -0.8440   -1.0780   -0.1205 C   0  0  0  0  0  0  0  0  0  0  0  0
   -1.3552    0.2331   -0.1102 C   0  0  0  0  0  0  0  0  0  0  0  0
   -2.8126    0.5061   -0.1900 C   0  0  0  0  0  0  0  0  0  0  0  0
   -3.7619   -0.3658    0.3754 C   0  0  0  0  0  0  0  0  0  0  0  0
   -5.1347   -0.1008    0.3061 C   0  0  0  0  0  0  0  0  0  0  0  0
   -5.5930    1.0523   -0.3227 C   0  0  0  0  0  0  0  0  0  0  0  0
   -4.6798    1.9331   -0.8908 C   0  0  0  0  0  0  0  0  0  0  0  0
   -3.3094    1.6572   -0.8317 C   0  0  0  0  0  0  0  0  0  0  0  0
   -0.4177    1.2799   -0.0177 C   0  0  0  0  0  0  0  0  0  0  0  0
    0.9584    1.0330    0.0475 C   0  0  0  0  0  0  0  0  0  0  0  0
    2.4994   -0.4674    0.0916 H   0  0  0  0  0  0  0  0  0  0  0  0
    0.8945   -2.3535   -0.0457 H   0  0  0  0  0  0  0  0  0  0  0  0
   -1.5134   -1.9313   -0.2025 H   0  0  0  0  0  0  0  0  0  0  0  0
   -3.4437   -1.2662    0.8961 H   0  0  0  0  0  0  0  0  0  0  0  0
   -5.8433   -0.7956    0.7492 H   0  0  0  0  0  0  0  0  0  0  0  0
   -6.6576    1.2635   -0.3694 H   0  0  0  0  0  0  0  0  0  0  0  0
   -5.0288    2.8364   -1.3842 H   0  0  0  0  0  0  0  0  0  0  0  0
   -2.6294    2.3598   -1.3084 H   0  0  0  0  0  0  0  0  0  0  0  0
   -0.7493    2.3157    0.0178 H   0  0  0  0  0  0  0  0  0  0  0  0
    1.6546    1.8659    0.1080 H   0  0  0  0  0  0  0  0  0  0  0  0
  1  2  1  0  0  0  0
  1 12  2  0  0  0  0
  1 13  1  0  0  0  0
  2  3  2  0  0  0  0
  2 14  1  0  0  0  0
  3  4  1  0  0  0  0
  3 15  1  0  0  0  0
  4  5  1  0  0  0  0
  4 11  2  0  0  0  0
  5  6  1  0  0  0  0
  5 10  2  0  0  0  0
  6  7  2  0  0  0  0
  6 16  1  0  0  0  0
  7  8  1  0  0  0  0
  7 17  1  0  0  0  0
  8  9  2  0  0  0  0
  8 18  1  0  0  0  0
  9 10  1  0  0  0  0
  9 19  1  0  0  0  0
 10 20  1  0  0  0  0
 11 12  1  0  0  0  0
 11 21  1  0  0  0  0
 12 22  1  0  0  0  0
M  END
>  <NO.>
1
>  <logX>
-2.52
$$$$
=====
Thanks for your assistance!

Best regards,

Rudy
_______________________________________________
OpenBabel-discuss mailing list
OpenBabel-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openbabel-discuss

Reply via email to