how to turn off AuxInfo when generating InChI

User cf4264f752

26-10-2011 13:56:01

Hi everyone!


I wonder how to turn off default generation of AuxInfo with InChI in Marvin Sketch from the structure I've just drawn

ChemAxon 5433b8e56b

28-10-2011 08:02:57

Hi,


i moved this topic to the Sturcture representation forum, because this question belongs to here. My collagues will answer you soon.


Regards,
Istvan

ChemAxon 0a9e2a55e1

28-10-2011 10:03:58

Hi,


The option for exporting inchi without AuxInfo is AuxNone.


In MarvinSketch Edit/Source window only the formats/options in the list can be used, no other options can be added. For inchi these are the standard inchi, and the inchikey. But AuxNone does not modify the first line (that starts with InChI=) so if You need it just check the first line and ignore the other.


If You need this, it can be done as a service. Do You need it locally or on the web? Locally it is a few lines of java code, compiles and set in the Preferences, then it can be reached in Tools/Services in a seperate window like the Edit/Source. In this case I can help You write the code and set the service. On the web it can also work as a web service, then one of my collegue can help You.


Best Regards,


Peter

User cf4264f752

28-10-2011 11:33:17

Hi, Peter


 


I need it locally in Marvin Sketch application, because users were a little bit confused - they didnt see AuxInfo within InChI before and they didn't even understand that the first line is regular InChI string at first. And actually they don't need this additional information. So if there's a rather simple way to set AuxNone within the standalone application I'll be grateful if you could share it.

ChemAxon 0a9e2a55e1

02-11-2011 10:54:56

Hi,


It can be done with services:


First a little code need to be written, with the function You want to use. In this case:


import chemaxon.struc.Molecule;

public class InchiExporter{
 public static String exportInchi(Molecule mol){
  return mol.toFormat("inchi:AuxNone");
 }
}

Then compile and make a jar from it. (I have made a service jar from this already, it is added as attachment.)


Then in Edit/Preferences on the Services tab click "Add new Service..." in the right menu (plus sign). Give a name to the service Select Local service as the service type, click the Browse button, and select the service jar You want to use.


Select the function in my case the exportInchi in the InchiExporter, then define the parameters, in my case only one parmater can be set, and I added a name for it (eg. "mol"),  and in Evaluation set "Active molecule". Click accept and the service is ready.


Now the choose the name of the service in Tools/Services, and it will be opened in a new window. You can see the result in the Source tab, and You can also choose "Calculate automatically", so You can always see the actual inchi as You draw in the sketcher window. (You can also minimize the structure and argument part if it is not needed.)


Best Regards,


Peter

User cf4264f752

24-12-2011 16:58:44

Hi, Peter!


Thanks for the fix. Unfortunately our chemists decided not to use marvin sketch