How to make absolute stereochemistry the default in MSketch?

User a11e9761d6

16-12-2011 00:25:47

Hi,


We're using the Marvin Applet (v. 5.7) in a web application. When you use it to draw a new structure, it defaults to relative stereochemistry (the CXSMILES has an "|r|" on the end). I know you can change this manually by going to  Structure > Add > Absolute Stereo (CHIRAL), but how can we make absolute stereochemistry the default? I was hoping to find a setting here http://www.chemaxon.com/marvin/help/developer/sketchman.html , but don't see anything.


Also, we need to allow people to draw relative stereochemistry if they want to, so just removing relative stereochemistry information from the CXSMILES won't work.


Thanks!


Krishna

User a11e9761d6

16-12-2011 19:23:26

I tried setting "molFormat" to "cxsmiles" in the hope that only the "mol" format defaults to relative stereochemistry, but that didn't fix it.


If I can't make absolute the default, how can I set it programatically when the applet launches?

ChemAxon 990acf0dec

20-12-2011 16:51:18

Hi,


Yes, the relative is the default, because in several applications where the Marvin Applet is used for drawing a query still the old MDL convention (and the old MOLFile format, V2000) is used, so if you draw a chiral query, the result might be false if the Absolute flag is automatically added ( http://www.chemaxon.com/jchem/doc/user/query_stereochemistry.html#chiralflag ).


Would you like to have the Absolute stereo flag automatically added, when you start drawing a stereo compound? And then, for drawing relative stereo compounds, is it enough if you remove the Absolute stereo flag manually using the Structure > Remove > Absolute stereo (CHIRAL) option?


Just one more note: since in case of the SMILES format the default is Absolute stereo, if you paste a SMILES (not a CXNSMILES!) on an empty canvas, the Absolute stereo label is automatically added.


Best regards,


Akos

User a11e9761d6

20-12-2011 19:18:35










akospapp wrote:

Would you like to have the Absolute stereo flag automatically added, when you start drawing a stereo compound? And then, for drawing relative stereo compounds, is it enough if you remove the Absolute stereo flag manually using the Structure > Remove > Absolute stereo (CHIRAL) option?



Thanks for the reply, Akos. Yes, this is exactly the behavior we would like.


In our application the user draws their structure, then we submit it to the server as a CXSMILES. By default CXSMILES should not have relative stereochemistry, but coming from the applet it does. We could circumvent this problem if you had a CXSMILES export option to to set the chiral flag, but I don't see one (we need to preserve enhanced stereochemistry features, of course).

How can we accomplish this?


Thanks,


Krishna

ChemAxon 5433b8e56b

28-12-2011 13:23:05

Hi Krishna,


as i understand, you need some export option to export absolute stereo chemistry information, and enchanced stereo information into cxsmiles, as it is possible to V3000 molfile format with mol:V3ea.


Is not the smiles:-le suitable for your needs? You can check the cxsmiles export options here.


I move this topic to the structure representation forum, my colleagues can help you more on these options.


Regards,
Istvan

ChemAxon 25dcd765a3

29-12-2011 08:29:04

Hi,


We don't have cxsmiles export option to avoid absolute/relative flag export alone. The export option suggested by Istvan will not preserve enhanced stereo information. Actually the relative/absolute and enhanced stereo information export is not separated, you can export all stereo information or none.


Akos is it possible to have the Absolute stereo flag automatically added, when you start drawing a stereo compound? In other words, to start the applet with Absolute stereo on.


This would be a solution.

ChemAxon 5433b8e56b

29-12-2011 13:58:25

Hi,


there is two parameter regarding this for the applet, the chiralitySupport, and the absLabel.


absLabel shows or hides the absolute label, chiralitySupport is for showing the atom chirality, but these are only visibility options.


We will check and discuss the possibility of an option which turns on absolute stereo on the structure automatically, or by default, and get back with the information.


Regards,
Istvan

User a11e9761d6

02-01-2012 17:50:09

Thanks for the clarification volfi; yes, I need to preserve enhanced stereochemistry, but would like to be able to start the applet with the chirality flag set. Having the chirality flag set is supposed to be the default for the CXSMILES format, so it seems reasonable that this should be an option. Please let me know what you decide.


Best regards,


Krishna

ChemAxon 5433b8e56b

10-01-2012 13:01:32

Hi,


finally we were able to gather all the information needed to know for the decision on how to implement this feature for you.


We can offer for you a method on the applet, which you can call before getting the structure from the applet, and sets the absolute stereo flag on the structure in the applet. This can be implemented until 5.9., if we try to make a parameter that turns automatically on the absolute stereo flag when stereo structure is drawn, or even when a simple structure is drawn, can be a bit complicated, and we can not finish it until 5.9.


Besides this applet method, as i understand you workflow, you can set this flag on the structure when using it on the server side. I assume, you have some java code on the server side so after importing the structure you can set the absolute stereo flag on it by calling the MoleculeGraph.setAbsStereo(boolean) method.


Is the server side suggestion suitable for your needs? Are you ok with the proposed applet method also?


Regards,
Istvan

User a11e9761d6

13-01-2012 00:24:04

Hi Istvan,


Thanks for the reply. We are already setting the chiral flag on the server side; the issue is that we have the applet insert the CXSMILES into a form field that the user can see. So right now when they draw a structure the CXSMILES always ends in |r|, but after they save and reload the page that 'r' flag is gone.


Krishna

ChemAxon 5433b8e56b

20-01-2012 14:35:44

Hi Krishna,


sorry for the late reply, i missed this topic unfortunatelly.


As i understand, you are changing the molecule to absolute stereo on the server side already. In this case, we will and can implement a method on the applet interface in the 5.9 version to set the absolute stereo flag on the structure in the applet, and with this method you can set the absolute stereo flag right before exporting the structure.


Does this seem to be a good solution for you?


Regards,
Istvan

User a11e9761d6

20-01-2012 19:02:22

Hi Istvan,


Being able to set the absolute stereo flag right before exporting the molecule would be a big improvement. However, there is one issue it would not resolve: if you have set the labeling of stereocenters to only show R/S labels on absolute stereocenters, they will not be shown prior to export because they are not considered absolute yet. The ideal solution would be to set the absolute stereo flag when starting the applet.


Thanks for your assistance,


Krishna

ChemAxon 5433b8e56b

25-01-2012 10:00:36

Hi Krishna,


we agreed to create a parameter in the applet, and to create the method in the applet interface to be able to set absolute stereo flag for the structure from javascript also.


The parameter as we now understand should work in the following way: if it is set, then the editor sets the absolute stereo flag for the structure, and keeps it set to the given value even if the strcuture is changed. In this case the user will not be able to set the stereo flag of the structure from the UI. This will prevent you to get a smiles with relative stereo chemistry, in any case, while exporting, if the parameter was set to absolute. Is this the way you would like to handle to structures, or we still misunderstand something?


Regards,
Istvan

User a11e9761d6

02-02-2012 00:33:36

Hi Istvan,


That sounds good, and would work well for us.


Thanks,


Krishna