Mnova processing scripts |
This reference contains a list of objects, functions and properties supported by Mnova script. For a complete ECMAScript Reference, consult this link.
Example scripts are present in the examples/scripts installation directory.
You can find the Mnova script reference documentation in the Mnova installation folder ('documents/scripts'), or by clicking on the 'Help' button in the scripts editor (or pressing F1 key).
NMRProcessing. Describing Processing parameters (Argument Strings). You will find in the Mnova installation folder: 'documents/scripts' a list of the argument strings (which have the form function1.function2...functionN.parameter) that you will be able to use in your processing scripts. These parameters appear in the graphical interface of the software (in the ‘Processing / Full Processing’ menu) and are described in depth in the manual of Mnova.
You can load a saved processing template by running this easy script:
//<GUI menuname="ApplyProcessingTemplate"shortcut="Ctrl+2"tooltip="Apply a saved processing template"/> function ApplyProcessingTemplate() { var spec = new NMRSpectrum( nmr.activeSpectrum() ); var processing = new String; if (!spec.isValid()) return; processing = "C:\\ProcessingTemplate.mnp"; nmr.processSpectrum(spec, processing); spec.process(); mainWindow.activeWindow().update(); }
Here you can see additional examples. This is a script to apply an Exponential apodization function of 0.5 Hz:
Here you can see an example to Bin your spectra with 0.025 ppm:
This is an example to apply a phase correction:
And this script can be used to reference your spectra:
You will find in the example/scripts folder a script called "customImportProcessing.qs", which will allow you to import your NMR spectra without applying any processing. If you add this script to a 'Script directory' you will obtain just the FID of your datasets. You can also edit the "customImportProcessing.qs" script to always apply a baseline correction when you import a dataset.
|