[Mne_analysis] trying to manually add a single trigger event

Krieger, Donald N. kriegerd at upmc.edu
Tue Apr 24 06:36:38 EDT 2012
Search archives:

Hi Jeff,

It looks like you are right, i.e. that you need an event file.  You can manufacture a .txt version which looks like this:
 42000 42.000       0   0
 42182 42.182       0  23

The first line details how long the delay was between the time that the acquisition was initiated and the time that the data began being saved.  So 42.000 sec is a subtractor.  I forget how to find this but the number is embedded in the raw data .fif file

The second line is the time at which the event occurs.  Since you specified "event 23" in your .ave file, use 23 as I have here.

One joker that may not apply.  I use a command that looks like this to generate an "average" from a single raw data trial:
   /home/kriegerd/Contrib/mne/bin/mne_process_raw                                       \
        --ave      /tmp/GenSingle.ave                                                    \
     --events   /tmp/GenSingle.eve                                \
     --raw      Data1_raw.fif            \
     --raw      Data1_raw.fif            \
     --gave     /tmp/GenSingle.fif

This uses the .eve file twice, on the two raw data files.  Note that they are the same.  So it averages 2 instances of the same thing.  When I wrote this I couldn't get it to work with a single trial.

Hope this helps.

Don

Don Krieger, Ph.D., D.ABNM
Department of Neurological Surgery
University of Pittsburgh
(412)648-9654
________________________________________
From: Jeff Eriksen [eriksenj at ohsu.edu]
Sent: Tuesday, April 24, 2012 1:30 AM
To: Krieger, Donald N.
Cc: mne_analysis at nmr.mgh.harvard.edu
Subject: Re: trying to manually add a single trigger event

Don et el.,

Please ignore my last post. I mistakenly thought the trigger file was
identical to the trigger channel. Now I think I need to add a trigger
channel, but do not know how. I have an EDF EEG file I am importing, but
it does not have any trigger events.

-Jeff

On 4/23/12 5:17 PM, "Krieger, Donald N." <kriegerd at upmc.edu> wrote:

>Hi Jeff,
>
>I'm not sure but I think you might need a tmin and tmin field inside your
>"category" braces, like this:
>  category {
>                    event 23
>                    tmin -0.25
>                    tmax 0.55
>                  }
>
>Don
>
>Don Krieger, Ph.D., D.ABNM
>Department of Neurological Surgery
>University of Pittsburgh
>(412)648-9654
>________________________________
>From: mne_analysis-bounces at nmr.mgh.harvard.edu
>[mne_analysis-bounces at nmr.mgh.harvard.edu] on behalf of Jeff Eriksen
>[eriksenj at ohsu.edu]
>Sent: Monday, April 23, 2012 8:11 PM
>To: mne_analysis at nmr.mgh.harvard.edu
>Subject: [Mne_analysis] trying to manually add a single trigger event
>
>I am trying to add a trigger event so I can average with N=1 in order to
>fake out mne_analyze to view my epoch as an average.
>
>Here is my text file for the trigger:
>            0 0 0 0 psuedo_event
>            10 0.009 0 1 trigger1
>
>Here is my text file to the averaging:
>
>
>average {
>
>outfile A1_ec1_bcm_epc1-ave.fif
>
>eventfile A1_triggers.txt
>
>logfile A1_ave_log.txt
>
>category {
>
>event 1
>
>}
>
>}
>
>Here is my result ­ note the syntax error at the end ­ what is wrong with
>my text file?
>Thanks,
>-Jeff
>
>kje-macbook:MNE jefferiksen$ mne_process_raw --raw A1_ec1_bcm_epc1.fif
>--filteroff --events A1_triggers.txt --ave A1_ave.txt --projoff
>
>mne_process_raw version 2.34 compiled at Jan  7 2011 02:27:27
>32-bit architecture. Using 1000.00 Mbytes for ring buffers
>
>--- Setting up the filter ---
>
>Using a 4096-point FFT in filtering of raw data with 2048-sample tapers
>bandpass =    0.0 (   0.0) ...   40.0 (   5.0) Hz
>filter is off
>
>--- Opening A1_ec1_bcm_epc1.fif ---
>
>No compensation data in A1_ec1_bcm_epc1.fif
>Compensation in file : uncompensated
>Setting up compensation data...
>No compensation set. Nothing more to do.
>No compensation was requested.
>A new compensation value (uncompensated) was assigned to 0 MEG channels.
>No SSS data in A1_ec1_bcm_epc1.fif
>0 bad channels read from A1_ec1_bcm_epc1.fif
>NOTE: Filter is presently switched off.
>NOTE: Filter is presently switched off.
>Initial dc offsets determined
>Raw data file A1_ec1_bcm_epc1.fif:
>nchan  = 257
>nsamp  = 900
>sfreq  = 1000.000 Hz
>length = 0.900    sec
>0 events found in A1_ec1_bcm_epc1-eve.fif
>Trigger channel : STI 014 max_event : 0
>No projection operator found in A1_ec1_bcm_epc1.fif
>Average EEG reference projection added.
>Projections turned off.
>
>--- Projection status ---
>
># 1 : Average EEG reference : 1 vecs : 257 chs EEG idle
>
>--- Averaging according to A1_ave.txt ---
>
>Was expecting a {
>






More information about the Mne_analysis mailing list