[Mne_analysis] Redefine Epochs based on different events

Jon Houck jhouck at mrn.org
Wed Mar 25 16:36:26 EDT 2020
Search archives:

        External Email - Use Caution        

Hi Edoardo,

With define_target_events, you can use a negative value in tmin to detect
targets that were preceded within some time window by a cue.  If I'm
remembering correctly, the target cue would be reference_id, the initial
cue would be the target_id, tmin would be the maximum lag between the two
(e.g., -3.0 if your variable delay can be up to 3 seconds), and tmax would
be 0.  You would want to look at both the original events and new_events
ndarrays to be sure that new_events contains only the targets of interest.

Hope this helps,

Jon




On Wed, Mar 25, 2020 at 2:02 PM Dan McCloy <dan at mccloy.info> wrote:

>         External Email - Use Caution
>
> A similar question came up just a few weeks ago on the mailing list, but
> it involved baselining epochs.  See this thread:
>
>
> https://mail.nmr.mgh.harvard.edu/pipermail//mne_analysis/2020-March/006551.html
>
> -- dan
> Daniel McCloy
> https://dan.mccloy.info
> Research Scientist
> Institute for Learning and Brain Sciences
> University of Washington
>
>
> ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> On Wednesday, March 25, 2020 9:40 AM, Edoardo Pinzuti <
> edoardo.pinzuti at gmail.com> wrote:
>
> *        External Email - Use Caution        *
>
>
>
>
> I can do it manually:  getting the data, cut every trial based on the time
> lags (all trials same length) and redefine the time axis with epochs.times
> , Is there a way to put back the data in the epoch object or create another
> one where an array (events,channels,time_points) can be passed? epochs.data
> does not work
>
> Thanks
>
>
> Il giorno mer 25 mar 2020 alle ore 14:29 Alexandre Gramfort <
> alexandre.gramfort at inria.fr> ha scritto:
>
>> *        External Email - Use Caution        *
>>
>>
>> hi,
>>
>> this is no straightforward equivalent to ft_redefinetrial in mne-python
>> as this stage.
>>
>> if you keep the stim channel in the epochs you have the information to do
>> this.
>>
>> someone with a clearer idea of the use case can maybe share some code.
>>
>> I never had to do this myself
>>
>> Alex
>>
>>
>> On Wed, Mar 25, 2020 at 11:57 AM Edoardo Pinzuti <
>> edoardo.pinzuti at gmail.com> wrote:
>>
>>> *        External Email - Use Caution        *
>>>
>>>
>>>   Dear MNE experts,
>>>
>>> My experiment  contains two cues in each trial with a variable delay in
>>> between,  I defined each condition base on cue and target cue  with
>>> mne.define_target_events.  Now my '0' in time is related to the first cue.
>>> How I can redefine my epochs based on the target cue (using the time lag
>>> between the two) so that the time '0' correspond to the appearance of the
>>> target cue on each trial? Is there a function similar  to ft_redefinetrial ?
>>>
>>>
>>> Thanks
>>> Edoardo
>>> _______________________________________________
>>> Mne_analysis mailing list
>>> Mne_analysis at nmr.mgh.harvard.edu
>>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>>
>> _______________________________________________
>> Mne_analysis mailing list
>> Mne_analysis at nmr.mgh.harvard.edu
>> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>>
>
> _______________________________________________
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis



-- 
Jon M. Houck, Ph.D.
Associate Professor
The Mind Research Network
1101 Yale Blvd. NE
Albuquerque, NM 87106
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20200325/548d3d6c/attachment-0001.html 


More information about the Mne_analysis mailing list