Monday, 21 January 2008

Careful with that mouse, Reader

If all NMR spectra were stored in a similar way (each spectrum into a single file, each file with an extension according to the format), it would be possible to map the extensions into the operative system and let the latter take care of all the translations, internally and transparently. It means that, when the user double clicks a spectrum, the computer can open it with the default "NMR browser" and, if any conversion of format is required, it is performed automatically and transparently. It's only a dream.
Only a few spectra arrive on the computer with a recognizable extension; most of them arrive as folders. Automatic management by the OS is out of question. We do it from within an application. The act of importing a spectrum has evolved in time, with increasing emphasis on automatic recognition. Despite the differences, the act changes very little from product to product. Take for example Jeol Delta. It's the most difficult-to-use NMR program I have ever come in contact with. I even asked the help of Jeol USA to enter the registration key, because I couldn't find my way. They were kind and fast to assist me.
Afterwards, the only thing I could find by myself was how to import a spectrum. There's nothing more I can do with Delta. The manual is long, dull and outdated. The program is colorful but cryptic. After all, if a product, that is both free and backed by a major firm, fails to become the no. 1 in popularity, there must be a reason...
Here's how you open a spectrum with Delta. Click the FID icon (into the main window). A dialog appears, which is not the standard dialog to choose a file. The purpose is similar, the look and the mechanisms are completely different. Now you select a format from the second menu. Then the most difficult part comes: navigating through the file system to find the spectrum. When the quests ends, press the "Ok" button and wait. The translation starts and it usually takes a long time. Sometimes it says: "Conversion failed", sometimes it works. In this case a new window ("1D Processor") appears, hiding the main window. A new file has been created into a folder called files/data, placed into your home directory. Unfortunately, when converting Bruker spectra, the file names are meaningless: fid-1.jdf, fid-2.jdf, ser-1.jdf, ser-2.jdf...

Last night a new version of iNMR reader shipped. What it does is obvious and revolutionary at the same time. iNMR reader exploits the most visible element of Mac OS X: the dock. The latter contains the icons of open applications and of preferred applications. Unless intentionally disabled, the dock is always visible. If you drag a spectrum onto the icon of iNMR reader 2.4.2, it is recognized, interpreted and opened. It's all automatic and it takes less than 1 second, even when the program is closed! Let me repeat it: less than 1 second, even if the program is closed !!! 15 formats are recognized: JCAMP-DX, Delta, GX, Alice, Varian, Bruker Avance, Bruker Aspect, Win-NMR, Spinsight, Siemens, NMRPipe, NT-NMR, MacNMR, GE Medical and, last but not least, SwaN-MR.
Consider a Varian spectrum. It's a directory, like "any-name.fid", containing the files "fid", "procpar" and "text". Which one shall we drag? The answer is: anything related! You can drag any of the inner files OR the folder "any-name.fid" (with or without extension) OR the folder surrounding it! Of course, this is not the only way you can open something with this program, there are also an "Open Recent" menu and the standard "Open" command.
There's more: if you drag a generic folder onto the icon, iNMR reader will open all the spectra therein contained. In theory, if the dragged folder contains thousands of spectra, you might lose the control of the process for minutes. This danger is prevented, because iNMR can't open more than 50 windows simultaneously. Another object you can drag is a picture file. If you drop it onto a spectrum, the inner picture is copied. In the case you have the free OpenBabel installed, you can drop directly a ChemDraw (.cdx) file on iNMR reader.
At this writing moment, the mother application (iNMR) doesn't implement translation by drag & drop. Do you know about any other NMR software that can do the same?

No comments:

Post a Comment