Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES from MOL-File

2019-07-18 Thread Wehner, Sebastian via Cdk-user
Legacy reasons i guess …. No actual reason not to upgrade, though.

From: John Mayfield 
Sent: Wednesday, July 17, 2019 10:51 AM
To: Wehner, Sebastian 
Cc: cdk-user@lists.sourceforge.net
Subject: Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES 
from MOL-File

Why were you using that version?

On Wed, 17 Jul 2019 at 06:37, Wehner, Sebastian 
mailto:sebastian.weh...@bruker.com>> wrote:
Hi John,

That is what I suspected. I had some hope that there was still a way to 
properly convert stereochemistry in this version…
Anyways, thanks for your quick answer and explanations.

Sebastian

From: John Mayfield 
mailto:john.wilkinson...@gmail.com>>
Sent: Tuesday, July 16, 2019 6:05 PM
To: Wehner, Sebastian 
mailto:sebastian.weh...@bruker.com>>
Cc: cdk-user@lists.sourceforge.net<mailto:cdk-user@lists.sourceforge.net>
Subject: Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES 
from MOL-File

Hi Sebastian,

> I am using CDK version 1.4.17

That is a very old version and does not convert stereochemistry correctly.  
Essentially there wasn't data structures to represent it so it was store 
different for 0D (e.g. SMILES) vs 2D vs 3D. This will all fixed about 7 years 
ago :-). Latest release is 2.2 BTW - https://github.com/cdk/cdk/releases

John

On Tue, 16 Jul 2019 at 15:04, Wehner, Sebastian via Cdk-user 
mailto:cdk-user@lists.sourceforge.net>> wrote:
Hi,

I could use your help! I am using CDK version 1.4.17 and want to build a SMILES 
string from a mol-file (SDF from lipid maps). The molecule has two isomers, but 
this information should be included in the mol-file, should it not?

Anyways, I pass the mol-file as ByteArrayInputStream into MDLV2000Reader and 
then create a new AtomContainer from this. Iterating over each atom of the 
AtomContainer, using a CDKAtomTypeMatcher to get the IAtomType of the atom 
which I then use to configure this atom with via 
AtomTypeManipulator.configure().

Finally adding implicit hydrogens to the AtomContainer, creating a 
SmilesGenerator and returning the smiles of the AtomContainer with 
smilesGenerator.createSMILES(AtomContainer).

However this produces a SMILES of the molecule which disregards the 
stereochemistry. The documentation states, that stereochemistry is taken into 
account 
(http://cdk.github.io/cdk/1.4/docs/api/org/openscience/cdk/smiles/SmilesGenerator.html).
 Am I missing something?

Would be great I someone could help! Added the link to lipid maps for the 
example: http://www.lipidmaps.org/data/LMSDRecord.php?LMID=LMGL02010378.


Best regards,
Sebastian Wehner

___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net<mailto:Cdk-user@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/cdk-user
___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdk-user


Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES from MOL-File

2019-07-17 Thread John Mayfield
Why were you using that version?

On Wed, 17 Jul 2019 at 06:37, Wehner, Sebastian 
wrote:

> Hi John,
>
>
>
> That is what I suspected. I had some hope that there was still a way to
> properly convert stereochemistry in this version…
>
> Anyways, thanks for your quick answer and explanations.
>
>
>
> Sebastian
>
>
>
> *From:* John Mayfield 
> *Sent:* Tuesday, July 16, 2019 6:05 PM
> *To:* Wehner, Sebastian 
> *Cc:* cdk-user@lists.sourceforge.net
> *Subject:* Re: [Cdk-user] Stereochemistry is disregarded when creating
> SMILES from MOL-File
>
>
>
> Hi Sebastian,
>
>
>
> > I am using CDK version 1.4.17
>
>
>
> That is a very old version and does not convert stereochemistry
> correctly.  Essentially there wasn't data structures to represent it so it
> was store different for 0D (e.g. SMILES) vs 2D vs 3D. This will all fixed
> about 7 years ago :-). Latest release is 2.2 BTW -
> https://github.com/cdk/cdk/releases
>
>
>
> John
>
>
>
> On Tue, 16 Jul 2019 at 15:04, Wehner, Sebastian via Cdk-user <
> cdk-user@lists.sourceforge.net> wrote:
>
> Hi,
>
>
>
> I could use your help! I am using CDK version 1.4.17 and want to build a
> SMILES string from a mol-file (SDF from lipid maps). The molecule has two
> isomers, but this information should be included in the mol-file, should it
> not?
>
>
>
> Anyways, I pass the mol-file as ByteArrayInputStream into MDLV2000Reader and
> then create a new AtomContainer from this. Iterating over each atom of
> the AtomContainer, using a CDKAtomTypeMatcher to get the IAtomType of the
> atom which I then use to configure this atom with via AtomTypeManipulator
> .configure().
>
>
>
> Finally adding implicit hydrogens to the AtomContainer, creating a
> SmilesGenerator and returning the smiles of the AtomContainer with
> smilesGenerator.createSMILES(AtomContainer).
>
>
>
> However this produces a SMILES of the molecule which disregards the
> stereochemistry. The documentation states, that stereochemistry is taken
> into account (
> http://cdk.github.io/cdk/1.4/docs/api/org/openscience/cdk/smiles/SmilesGenerator.html).
> Am I missing something?
>
>
>
> Would be great I someone could help! Added the link to lipid maps for the
> example: http://www.lipidmaps.org/data/LMSDRecord.php?LMID=LMGL02010378.
>
>
>
>
>
> Best regards,
>
> Sebastian Wehner
>
>
>
> ___
> Cdk-user mailing list
> Cdk-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/cdk-user
>
>
___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdk-user


Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES from MOL-File

2019-07-16 Thread Wehner, Sebastian via Cdk-user
Hi John,

That is what I suspected. I had some hope that there was still a way to 
properly convert stereochemistry in this version…
Anyways, thanks for your quick answer and explanations.

Sebastian

From: John Mayfield 
Sent: Tuesday, July 16, 2019 6:05 PM
To: Wehner, Sebastian 
Cc: cdk-user@lists.sourceforge.net
Subject: Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES 
from MOL-File

Hi Sebastian,

> I am using CDK version 1.4.17

That is a very old version and does not convert stereochemistry correctly.  
Essentially there wasn't data structures to represent it so it was store 
different for 0D (e.g. SMILES) vs 2D vs 3D. This will all fixed about 7 years 
ago :-). Latest release is 2.2 BTW - https://github.com/cdk/cdk/releases

John

On Tue, 16 Jul 2019 at 15:04, Wehner, Sebastian via Cdk-user 
mailto:cdk-user@lists.sourceforge.net>> wrote:
Hi,

I could use your help! I am using CDK version 1.4.17 and want to build a SMILES 
string from a mol-file (SDF from lipid maps). The molecule has two isomers, but 
this information should be included in the mol-file, should it not?

Anyways, I pass the mol-file as ByteArrayInputStream into MDLV2000Reader and 
then create a new AtomContainer from this. Iterating over each atom of the 
AtomContainer, using a CDKAtomTypeMatcher to get the IAtomType of the atom 
which I then use to configure this atom with via 
AtomTypeManipulator.configure().

Finally adding implicit hydrogens to the AtomContainer, creating a 
SmilesGenerator and returning the smiles of the AtomContainer with 
smilesGenerator.createSMILES(AtomContainer).

However this produces a SMILES of the molecule which disregards the 
stereochemistry. The documentation states, that stereochemistry is taken into 
account 
(http://cdk.github.io/cdk/1.4/docs/api/org/openscience/cdk/smiles/SmilesGenerator.html).
 Am I missing something?

Would be great I someone could help! Added the link to lipid maps for the 
example: http://www.lipidmaps.org/data/LMSDRecord.php?LMID=LMGL02010378.


Best regards,
Sebastian Wehner

___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net<mailto:Cdk-user@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/cdk-user
___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdk-user


Re: [Cdk-user] Stereochemistry is disregarded when creating SMILES from MOL-File

2019-07-16 Thread John Mayfield
Hi Sebastian,

> I am using CDK version 1.4.17

That is a very old version and does not convert stereochemistry correctly.
Essentially there wasn't data structures to represent it so it was store
different for 0D (e.g. SMILES) vs 2D vs 3D. This will all fixed about 7
years ago :-). Latest release is 2.2 BTW -
https://github.com/cdk/cdk/releases

John

On Tue, 16 Jul 2019 at 15:04, Wehner, Sebastian via Cdk-user <
cdk-user@lists.sourceforge.net> wrote:

> Hi,
>
>
>
> I could use your help! I am using CDK version 1.4.17 and want to build a
> SMILES string from a mol-file (SDF from lipid maps). The molecule has two
> isomers, but this information should be included in the mol-file, should it
> not?
>
>
>
> Anyways, I pass the mol-file as ByteArrayInputStream into MDLV2000Reader and
> then create a new AtomContainer from this. Iterating over each atom of
> the AtomContainer, using a CDKAtomTypeMatcher to get the IAtomType of the
> atom which I then use to configure this atom with via AtomTypeManipulator
> .configure().
>
>
>
> Finally adding implicit hydrogens to the AtomContainer, creating a
> SmilesGenerator and returning the smiles of the AtomContainer with
> smilesGenerator.createSMILES(AtomContainer).
>
>
>
> However this produces a SMILES of the molecule which disregards the
> stereochemistry. The documentation states, that stereochemistry is taken
> into account (
> http://cdk.github.io/cdk/1.4/docs/api/org/openscience/cdk/smiles/SmilesGenerator.html).
> Am I missing something?
>
>
>
> Would be great I someone could help! Added the link to lipid maps for the
> example: http://www.lipidmaps.org/data/LMSDRecord.php?LMID=LMGL02010378.
>
>
>
>
>
> Best regards,
>
> Sebastian Wehner
>
>
> ___
> Cdk-user mailing list
> Cdk-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/cdk-user
>
___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdk-user


[Cdk-user] Stereochemistry is disregarded when creating SMILES from MOL-File

2019-07-16 Thread Wehner, Sebastian via Cdk-user
Hi,

I could use your help! I am using CDK version 1.4.17 and want to build a SMILES 
string from a mol-file (SDF from lipid maps). The molecule has two isomers, but 
this information should be included in the mol-file, should it not?

Anyways, I pass the mol-file as ByteArrayInputStream into MDLV2000Reader and 
then create a new AtomContainer from this. Iterating over each atom of the 
AtomContainer, using a CDKAtomTypeMatcher to get the IAtomType of the atom 
which I then use to configure this atom with via 
AtomTypeManipulator.configure().

Finally adding implicit hydrogens to the AtomContainer, creating a 
SmilesGenerator and returning the smiles of the AtomContainer with 
smilesGenerator.createSMILES(AtomContainer).

However this produces a SMILES of the molecule which disregards the 
stereochemistry. The documentation states, that stereochemistry is taken into 
account 
(http://cdk.github.io/cdk/1.4/docs/api/org/openscience/cdk/smiles/SmilesGenerator.html).
 Am I missing something?

Would be great I someone could help! Added the link to lipid maps for the 
example: http://www.lipidmaps.org/data/LMSDRecord.php?LMID=LMGL02010378.


Best regards,
Sebastian Wehner

___
Cdk-user mailing list
Cdk-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdk-user