Am I missing an option, or is OB tromping on my chiral flag?
Using Open Babel 2.3.0, as the script below shows, a mol file
with chiral flag set is read in, but when written out, it is gone?

-- Dave Nunn

#!/usr/bin/perl
use strict;
use Chemistry::OpenBabel;
undef($/);
my $molfile = <DATA>;
my $obmol = new Chemistry::OpenBabel::OBMol;
my $obconversion = new Chemistry::OpenBabel::OBConversion;
$obconversion->SetInAndOutFormats('sdf', 'sdf');
$obconversion->ReadString($obmol, $molfile);
print $obconversion->WriteString($obmol);
__END__
(S)-2-butanol
 OpenBabel06041121052D

  6  5  0  0  1  0  0  0  0  0999 V2000
   -1.7321    1.0000    0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
   -1.7321    0.0000    0.0000 C   0  0  2  0  0  0  0  0  0  0  0  0
   -2.2321   -0.8660    0.0000 H   0  0  0  0  0  0  0  0  0  0  0  0
   -2.7321    0.0000    0.0000 O   0  0  0  0  0  0  0  0  0  0  0  0
   -0.8660   -0.5000    0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
    0.0000   -0.0000    0.0000 C   0  0  0  0  0  0  0  0  0  0  0  0
  1  2  1  0  0  0  0
  2  3  1  6  0  0  0
  2  4  1  0  0  0  0
  2  5  1  0  0  0  0
  5  6  1  0  0  0  0
M  END


--
View this message in context: 
http://forums.openbabel.org/Chiral-flag-lost-tp3574482p3574482.html
Sent from the openbabel-scripting mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Simplify data backup and recovery for your virtual environment with vRanger.
Installation's a snap, and flexible recovery options mean your data is safe,
secure and there when you need it. Discover what all the cheering's about.
Get your free trial download today. 
http://p.sf.net/sfu/quest-dev2dev2 
_______________________________________________
OpenBabel-scripting mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbabel-scripting

Reply via email to