[Mne_analysis] capping number of trials per condition in -gave.fif using mne_process_raw

Matti Hamalainen msh at nmr.mgh.harvard.edu
Mon Jul 23 10:49:17 EDT 2012
Search archives:

On Jul 23, 2012, at 5:05 PM, Matthew Panichello wrote:

> Hello,
> 
> I'm using mne_process_raw to create grandaveraged data for each individual subject. Each subject's data were collected over five runs and so are saved in 5 raw fiff files.
> 
> The task included 5 different trial types presented in a mixed-event design. I'd like to set a cap on the number of trials per condition, such that even if a subject completed 90 trials of Condition #1 over the 5 runs, for example, only the first 75 will be saved in his grandaverage file.
> 
> I tried to implement this by writing a matlab script that reads the event files for each run and removes events from each condition until the cap is met. But, for some subjects, this results in a completely empty event file for run 5 (the script begins with the last run), causing mne_process_raw to exit when I actually try to produce the average. 
> 
> Is anyone aware of a simpler way to control the number of trials used to compute the grandaverage using mne_process_raw?
> 
> Also, while I was working on this, I noticed the following window output by process_raw:
> "filter: .5 .... 120 Hz  bins : 6 .... 1636 of 4097 hpw : 3 lpw : 34
> Highpass filter will work as specified
> filter: 0 .... 40 Hz  bins : 0 .... 545 of 4097 hpw : 3 lpw : 34
> Highpass filter will work as specified"
> 
> I specify a 120 Hz lp filter and a .5 Hz hp filter in my input to process_raw, so I was surprised to see what seems to be an additional 40 Hz lp filter being applied. Can anyone comment on why this might be? 

Hi Matt,

You are using the nightly build which has a separate filter setting for EOG. mne_process_raw --help reveals:

        --eoghighpass val/Hz      EOG highpass corner (default =    0.0 Hz)
        --eoglowpass  val/Hz      EOG lowpass  corner (default =   40.0 Hz)
        --eoghighpassw val/Hz     EOG highpass transition width (default =    0.0 Hz)
        --eoglowpassw val/Hz      EOG lowpass transition width (default =    5.0 Hz)

In your particular example, the MEG/EEG data are filtered from 0.5 to 120 Hz according to your specification but the default lowpass (40 Hz) is used for EOG.

- Matti




---------

Matti Hamalainen, Ph.D.
Athinoula A. Martinos Center for Biomedical Imaging
Massachusetts General Hospital

msh at nmr.mgh.harvard.edu
mhamalainen at partners.org






-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20120723/87a9b1e7/attachment.html 


More information about the Mne_analysis mailing list