i like this post (click again to cancel)
1
i dont like this post (click again to cancel) remove favorite mark from this question (click again to restore mark)

I have an fid file (for a 2D experiment) that I would like to process in vnmr. I am aware that an fid file requires a certain header to be able to be processed in vnmr. How do I add a header to my fid file, such that I can process the data in vnmr?

asked Nov 19 '09 at 17:13

KevinJD's gravatar image

KevinJD
16

updated Jan 18 '10 at 11:25

Evgeny%20Fadeev's gravatar image

Evgeny Fadeev
5771


3 Answers:
i like this answer (click again to cancel)
2
i dont like this answer (click again to cancel)

I'm not sure I understand your question. If the fid is produced by varian software, then it will already have the necessary headers (note the plural) prepended to the data. If data is from another brand of spectrometer, I believe Varian has utilities to convert the data to their format, complete with the necessary headers.

If the fid is from another source (say a simulated or synthetic fid) then you will have to pre-pend a file header to the entire file, and a block header to each block of data. These are well described in the Varian user programming manual. If necessary, I can send you class definitions that describe the headers. These are used by SpinWorks to read Varian data but could also be used to write Varian compatible data if you have some programming experience.

link

answered Nov 22 '09 at 14:43

Kirk%20Marat's gravatar image

Kirk Marat
711

updated Jan 07 '10 at 09:52

i like this answer (click again to cancel)
2
i dont like this answer (click again to cancel)

I've written a binary parser for the varian fid files. Below is the output.
The global header in varian FID files define a meta data parameter S_COMPLEX.
Additionally, each FID block defines the np_cmplx, ni_cmplex,and ni2_cmplx.
I'm reading all of these values in as false !!! This implies that my fid is not complex... And I know that, in fact, my fid file is complex.

So my confusion is as follows : Why does my fid meta data appear to be telling me that my fid points are real, as opposed to complex ?

Here is the output of my program. As you can see, many of the meta data parameters look reasonable, implying that the parser basically works okay. For example, it is getting reasonable values for the number of points, the data flag, the fid flag, the number of traces, etc.... but all the boolean flags for "complex" vs "real" seem to be off.

////////////////////////////////////////
data true
fid true

There are 1 block headers in this file type. 
    np  complex false
    ni  complex false
    ni2 complex false
    nf complex false
    more false

Added 12 meta data parameters out of 12

1 : FILE_NUM_TYPE = Integer
2 : BLOCK_HEADER_SKIP_SIZE = 28
3 : FILE_NUM_RC = Real
4 : FILE_GLOBAL_FOOTER = 0
5 : FILE_DATA_ORDER = INTERLEAVED
6 : FILE_AMOUNT_OF_DATA_FILES = 1
8 : DEBUG1 = {bytesPerTrace=8192.0, bytesPerElement=4.0, elementsPerTrace=2048.0, bytesPerTrace/bytesPerElement=2048.0}
9 : FILE_BLOCK_COUNT = 256
10 : FILE_GLOBAL_HEADER = 32
11 : BLOCK_FOOTER_SKIP_SIZE = 0
12 : FILE_ENDIAN = BIG_ENDIAN
link

answered Jan 18 '10 at 05:50

j's gravatar image

j
131

updated Jan 18 '10 at 10:54

Evgeny%20Fadeev's gravatar image

Evgeny Fadeev
5771

Hey J, I think it's better if you post it as a separate question. This is Q&A, unlike in discussion threads answers do not always show in the same order. Cheers. - Evgeny Fadeev (Jan 18 '10 at 11:01)

btw, since you now have 21 points you can upvote :). If you find anything interesting - please vote those posts up. Commenting everywhere requires 50 points, but you can always comment your own posts and answers to your questions. - Evgeny Fadeev (Jan 18 '10 at 11:06)

Take a look at your binary file with some capable text editor, like vim: http://vimdoc.sourceforge.net/htmldoc/vimfaq.html#36.1 - if those bytes are indeed set correctly then there has to be a bug in your header reader. - Evgeny Fadeev (Jan 18 '10 at 13:37)

also there is a linux program "od" that dumps out file content in various formats byte-by-byte - Evgeny Fadeev (6 mins ago) - Evgeny Fadeev (Jan 18 '10 at 13:47)

i like this answer (click again to cancel)
0
i dont like this answer (click again to cancel)

I have a varian fid which I know to be complex, but where the header parameters npcmplx,nicmplx are both valued at 0, in the first block header. Other than that the fid seems to be fine. Is there a reason for this ?

link

answered Jan 18 '10 at 04:45

j's gravatar image

j
131

Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a good answer, for discussions, please use comments and please do remember to vote (login to vote)
toggle preview

powered by CNPROG