[Eeglablist] examples of how to get numerical data out of ERSP and specturm?

Arnaud Delorme arno at ucsd.edu
Mon Mar 26 17:25:41 PDT 2012


Dear Andrew,

the erspdata array in the call below 

[STUDY erspdata ersptimes erspfreqs] = std_erspplot(STUDY,ALLEEG,'channels',{'Fp1'});

is a n x m cell array. n and m depend on your study design. To make it simple, create a very simple design with only 1 condition per subject (then n = 1 and m = 1) and erspdata will be a cell array of 1 x 1.

The array in erspdata is for example 50 x 200 x 10. 50 frequencies, 200 time points and 10 subjects/components. You may average the last dimension and export to a text file.

tmperspdata = mean(erspdata{1},3);
save -ascii myfile.txt tmperspdata

Alternatively, you might want to preserve the subject/component information, so in this case, you would transform the ERSP 2-D image into a 1-D vector

tmperspdata = reshape(erspdata{1},size(erspdata{1},1)*size(erspdata{1},2), size(erspdata{1},3));
save -ascii myfile.txt tmperspdata

Hope this helps,

Arno

On Mar 19, 2012, at 2:26 PM, Andrew Hill wrote:

> Hi Arno, and list.
> 
> I'm still chasing the elusive extraction of numerical ERSP data.  
> 
> I'm able to get the times and frequencies out per the example below, but my "erspdata" is a 3 * 4 array of [4-D Double] structures, e.g. session * group.  Is there a straightforward way to export a summary of these to facilitate import into Excel, SPSS, etc?  
> 
> I've been spoiled by how much I can do with EEGLab without stellar matlab skills; any advice here is welcome :)
> 
> Best,
> andrew
> 
> 
> On May 25, 2011, at 10:04 PM, Arnaud Delorme wrote:
> 
>> Dear Andrew,
>> 
>> After plotting STUDY measures, look at the history 
>> 
>> STUDY = std_erspplot(STUDY,ALLEEG,'channels',{'Fp1'});
>> 
>> Then add output to the command line call (look up the function help for more information)
>> 
>> [STUDY erspdata ersptimes erspfreqs] = std_erspplot(STUDY,ALLEEG,'channels',{'Fp1'});
>> 
>> Best,
>> 
>> Arno
>> 
>> On Apr 28, 2011, at 1:48 PM, Andrew Hill wrote:
>> 
>>> Hi folks,
>>> 
>>> Can anyone give me an example of how to get numerical data out of ERSP or spectral computations?
>>> 
>>> I've done a lot of "precompute channel measures" for STUDYs, but I'm not sure how to produce "numbers" instead of plots for ERSP, spectral, etc... 
>>> 
>>> I do see the command window output that says "Add output variables to command line call in history to retrieve results" but an example or two would go a long way to helping this less-than-expert Matlab user.
>>> 
>>> Best,
>>> Andrew
>>> 
>>> 
>>> _______________________________________________
>>> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
>>> To unsubscribe, send an empty email to eeglablist-unsubscribe at sccn.ucsd.edu
>>> For digest mode, send an email with the subject "set digest mime" to eeglablist-request at sccn.ucsd.edu
>> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20120326/0e1d3ace/attachment.html>


More information about the eeglablist mailing list