[FieldTrip] Beginner in FieldTrip: EEGLab to FieldTrip + SSVEP Analysis

Poppy Watson popwatson at hotmail.com
Tue May 21 01:39:56 CEST 2019


Hi Danielle
You can use your existing bins – you need to define your import file and the event types and  values.

So first find out what those are using the code provided on the wiki page below e.g., something like



events = ft_read_event( EEGLABFILE, 'header', hdr );

Then you need to import your data to field trip using something like the following – note that this was data pre-processed and imported from BVA but steps will be similar:

cfg = [];
cfg.dataset = filename;
cfg.trialdef.eventtype = 'Stimulus'; %[this will change depending on what your event types actually are]
cfg.trialdef.eventvalue = 'S120’; %[that was mine, obviously yours will be different]
cfg.trialdef.prestim    = 2; %seconds - import as much around your event marker as you have/need
cfg.trialdef.poststim   = 0.5; %ditto
cfg = ft_definetrial(cfg); %[this is just using the standard trialfun but you might want to write your own]

MypreProcData = ft_preprocessing(cfg);

Hope this helps.

---------------------------------------------------------------------
Poppy Watson

From: fieldtrip <fieldtrip-bounces at science.ru.nl> On Behalf Of Taylor, Danielle
Sent: Tuesday, 21 May 2019 6:25 AM
To: FieldTrip discussion list <fieldtrip at science.ru.nl>
Subject: Re: [FieldTrip] Beginner in FieldTrip: EEGLab to FieldTrip + SSVEP Analysis

Thank you very much Dr. Delorme,

I appreciate the information you shared, and have referenced the EEGLab website for converting data to FieldTrip.

However, I am still left with a couple questions after referencing the website. Is it okay to import data to FieldTrip that has already been assigned bins in EEGLab or would I need to import the data from back a few steps and then assign bins using EEGLab? In addition, I am still unclear on how to evaluate specific windows for evaluating the SSVEP (400-700 ms, 700-1000, 1000-2000 and 2000-3000).

Again, apologies if these questions appear ill-informed. I have read several posts from the forum and watched/read several tutorials, and I am not quite sure how to begin.

Thank you again!

Danielle Taylor, M.S.
Doctoral Candidate,
Clinical Psychology
Oklahoma State University

Breach of Confidentiality or Accidental Breach of Confidentiality: This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed.  If you have received this email in error please notify the sender. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute, or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited.


On Mon, May 20, 2019 at 11:32 AM Arnaud Delorme <arno at ucsd.edu<mailto:arno at ucsd.edu>> wrote:
Dear Danielle,

check out these two wiki pages.

https://sccn.ucsd.edu/wiki/EEGLAB_and_Fieldtrip#Converting_between_EEGLAB_and_Fieldtrip_data_structures
https://sccn.ucsd.edu/wiki/A08:_DIPFIT#Advanced_source_reconstruction_using_DIPFIT.2FFieldtrip

Best wishes,

Arno


On May 20, 2019, at 9:03 AM, Taylor, Danielle <danielle.taylor at okstate.edu<mailto:danielle.taylor at okstate.edu>> wrote:

Hello FieldTrippers,

My name is Danielle Taylor and I am a graduate student at Oklahoma State University. I am currently trying to learn to use FieldTrip, and I am quite the novice. I am, however, quite familiar with EEGLab, and have previously used Matlab to run EEGLab processes.

 I am currently processing data for a study in which I am evaluating an ERP (the LPP) and the SSVEP. I have compiled my ERPs, and therefore hoped to import my EEGLab data to Fieldtrip and complete SSVEP analyses.

My questions are quite broad.
1) Can I import EEGLab data that has been processed through artifact rejection (I have used filters, ICA, have data binned and epoched, and have run automated artifact rejection routines)? Is it possible to import from this point and then complete fourier transformation in fieldtrip? If so, how? I have seen that one can use eeglab2fieldtrip, but do I need other specifications in my code? Alternatively, the EEGLab website recommends this code:
hdr = ft_read_header( EEGLABFILE );

data = ft_read_data( EEGLABFILE, 'header', hdr );

events = ft_read_event( EEGLABFILE, 'header', hdr );
Does it matter which method I use?

2) I am evaluating the SSVEP in 4 separate windows that are the same measurements as my ERP (400-700ms, 700-1000, 1000-2000 and 2000-3000). I have seen samples of code that use a moving window, but not that have used specific windows such as this.

I apologize if these questions are too vague, but any help or even a sample script would be much appreciated. Thank you very much for your assistance in advance!

Regards,

Danielle Taylor, M.S.
Doctoral Candidate,
Clinical Psychology
Oklahoma State University

Breach of Confidentiality or Accidental Breach of Confidentiality: This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed.  If you have received this email in error please notify the sender. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute, or copy this email. Please notify the sender immediately by email if you have received this email by mistake and delete this email from your system. If you are not the intended recipient you are notified that disclosing, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited.
_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
https://doi.org/10.1371/journal.pcbi.1002202

_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
https://doi.org/10.1371/journal.pcbi.1002202
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20190520/d9c9d4d7/attachment-0002.html>
-------------- next part --------------
_______________________________________________
fieldtrip mailing list
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
https://doi.org/10.1371/journal.pcbi.1002202


More information about the fieldtrip mailing list