[Mne_analysis] Writing EEG (.edf, .mat, or .txt) data to .fif with MEG data

tapsya at nmr.mgh.harvard.edu tapsya at nmr.mgh.harvard.edu
Wed Oct 5 20:46:55 EDT 2011
Search archives:

Hi Brian,

Please ignore my previous message, it was incomplete and had no
attachment. [I hit 'send' by mistake. Apologies!!].

To convert .edf to .fif please use the command 'mne_edf2fiff'.

Usage:
mne_edf2fiff --edf your_edf_file_name.edf --fif
your_resultant_fif_file_name_raw.fif

In this email, you will find my code as an attachment which is a matlab
code 'Combine_fiff.m'. This code accepts two .fif files with different
sampling frequencies, matches it and then synchronizes the triggers.
Sounds like you do not need it and plus it will not work for you [since
you will need another .m file for it to work].

However, the code does contain mne matlab commands to combine two .fif
files into one and will help you also to handle the header information for
the new .fif file. I have commented sections in the code which I think may
be helpful to you.

Hope this helps. Let me know if you have further questions.


Thanks.

Wishes,
Tapsya Nayak
>
> Hi Brian,
>
> Also, Tapsya (cc'd) has combined EEG and EMG data acquired with a TMS
system. She most probably has helpful Matlab code.
>
> - Matti
>
>
>
> On Oct 5, 2011, at 10:13 AM, Alexandre Gramfort wrote:
>
>> hi Brian,
>> I've never done what you describe but I would try the following.
Convert the EEG to fif with mne_edf2fiff and then merge the 2 fif files
with matlab or python. Assuming the timings are good, it should consist in
concatenating the channels and the data. It's not
>> straightforward but you could give it a try inspired by:
>> https://github.com/mne-tools/mne-matlab/blob/master/matlab/mne_ex_read_write_raw.m
Best,
>> Alex
>> On Tue, Oct 4, 2011 at 3:09 PM, Brian Coffman <bcoffman at mrn.org> wrote:
>>> Hello MNE analyzers,
>>> I am acquiring continuous EEG data using the EGI sensor net, which
cannot be
>>> piped into the fif file at acquisition. I would like to combine the
raw
>>> MEG
>>> and EEG data into a single .fif file. This data is available in edf
mat
>>> and
>>> txt (tab delimited) format, but I cannot determine an easy way to get
the
>>> matrix into the fif files. From reviewing the manuals, it seems that
the
>>> mne_edf2fiff tool may be the way to go, but I am not sure how to use
this
>>> tool to write the edf data to an existing MEG data set. Has anyone
encountered this problem? Any suggestions or ideas?
>>> --
>>> -Brian Coffman, M.S.
>>> Research Associate, The Mind Research Network
>>> Doctoral Candidate, The University of New Mexico
>>> Phone: (505) 336-0606
>>> Fax: (505) 272-7011
>>> "I used to think that the brain was the most wonderful organ in my
body.
>>> Then I realized who was telling me this."
>>>   - Emo Phillips
>>> _______________________________________________
>>> Mne_analysis mailing list
>>> Mne_analysis at nmr.mgh.harvard.edu
>>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis The
information in this e-mail is intended only for the person to whom it is
>>> addressed. If you believe this e-mail was sent to you in error and the
e-mail
>>> contains patient information, please contact the Partners Compliance
HelpLine at
>>> http://www.partners.org/complianceline . If the e-mail was sent to you
in
>>> error
>>> but does not contain patient information, please contact the sender
and
>>> properly
>>> dispose of the e-mail.
>> _______________________________________________
>> Mne_analysis mailing list
>> Mne_analysis at nmr.mgh.harvard.edu
>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>
>
>
> ---------
>
> Matti Hamalainen, Ph.D.
> Athinoula A. Martinos Center for Biomedical Imaging
> Massachusetts General Hospital
>
> msh at nmr.mgh.harvard.edu
>
>
>
>
>
>
>



-------------- next part --------------
A non-text attachment was scrubbed...
Name: Combine_fiff.m
Type: text/x-objcsrc
Size: 9065 bytes
Desc: not available
Url : http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20111005/1fa212da/attachment.bin 


More information about the Mne_analysis mailing list