importing EGI Net Station EEG data into MNE

The subject line says it all. I looked at the manual, and the options seem to be EDF/BDF or Biosemi files. Since there is a Matlab MNE Toolbox, has anyone yet added m-files that can create FIF files from Matlab data? That would work well for me, since Net Station can export into Matlab format.

-Jeff
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20111019/5e19916b/attachment.html

Hi Jeff,

The subject line says it all. I looked at the manual, and the options seem
to be EDF/BDF or Biosemi files. Since there is a Matlab MNE Toolbox, has
anyone yet added m-files that can create FIF files from Matlab data? That
would work well for me, since Net Station can export into Matlab format.

you can do such a conversion with the matlab toolbox available at:

a good starting example is :

but maybe someone has an already written script to do this.

hope this helps

Alex

Alex,

I am just getting back to this topic. When I first saw your email, I
thought you were pointing me to a separate MNE Matlab toolbox, but this
is just the same Matlab scripts that come with the MNE distribution. I do
not yet know enough to be able to understand these or use them properly.
My overall goal is this:

Start with probe.elp file containing electrode coordinates
Start with Matlab file with EEG data )and basic info such as sampling rate
and number of channels)
Convert the above to a fif file (best I can tell now is that they are
combined in a single fif file?)
Run FreeSurfer on my T1 MRI (this I can do OK)

At this point I should be able to take my own data and follow the example
in Chapter 12 to register the electrodes to the MRI, generate a source
model and solve the forward and then inverse problems.

I do not see how I can get my data in and save as a fif file using these
Matlab scripts. Probably some combination of them can. I will continue
reading the MNE manual from the beginning now, I guess.

TIA for any further suggestions.
-Jeff

Alex,

Looking at mne_ex_read_write_raw, perhaps I am getting an inkling of what
to do now. I am confused by the use of "raw" in this script and indeed the
whole manual. What does "raw" mean? My definition would be just a 2D array
of EEG with no other information. But it appears that this example reads
and writes to fif files, so I will just guess that these routines will
work for me. Assuming I already have my EEG array in memory, I would then
use the following to write the data to a fif file: (??)

[outfid,cals] = fiff_start_writing_raw(outfile,raw.info,picks);
      fiff_write_int(outfid,FIFF.FIFF_FIRST_SAMPLE,first);
    fiff_write_raw_buffer(outfid,data,cals);
fiff_finish_writing_raw(outfid);

It appears that I will also need to define picks, using

        picks =
fiff_pick_types(raw.info,want_meg,want_eeg,want_stim,include,raw.info.bads)
;

I will read up on these individual routines to see it they do what I
expect.

Let me know if I am on the right track,
-Jeff

Dear Jeff,

I am really sorry but I've never worked with EGI data so I cannot really
help more on this.

I know that Matti has recently worked to improve the mne_edf2fif command.

Hari in CC might also have some experience with this.

Cheers,
Alex

Hi all,

I have been improving mne_edf2fiff and have tested the changes in an off-line discussion with Jeff. I can soon post precise information on how to proceed.

BTW, I think the EDF route is quite a reliable option.

- Matti