[Mne_analysis] shifting time-scale in RAW data

Stephen Politzer-Ahles spa268 at nyu.edu
Tue Apr 29 05:54:54 EDT 2014
Search archives:

Hi Lau,

I thought there was a function for this on raw data but I can no longer
find it (so I too would be interested to hear what others have to say). But
it should be possible to do this in sort of a hack-ish way by just shifting
the times of the events in the event table. For example:

# Get the event list events = mne.find_events( raw, min_duration = .002 )

# Adjust the trigger latencies
events[:,0] = [ x + 25 for x in events[:,0] ]

Alternatively, I suppose you could just pull out bigger epochs (e.g., 25 ms
longer than you intend) in the beginning, then use evoked.shift_time later,
and make sure to leave off the first 25 ms of the epoch in your plotting
and analysis. But yes, it would be great if there is a cleaner way to do
this.

Best,
Steve



Stephen Politzer-Ahles
New York University, Abu Dhabi
Neuroscience of Language Lab
http://www.nyu.edu/projects/politzer-ahles/


On Tue, Apr 29, 2014 at 1:34 PM, Lau Møller Andersen
<lau.andersen at cnru.dk>wrote:

> Dear list
>
> I am aware of how to shift the time-scale in evoked files:
>
> http://martinos.org/mne/stable/auto_examples/plot_shift_evoked.html#example-plot-shift-evoked-py
>
> But is it possible to do it already on the raw file? (I have a trigger
> delay of 25 msec.)
>
> The reason for this being preferable in my view is that if you do it after
> having epoched, you effectively include 25 msec of data before the epoch
> that does not belong to the epoch. Furthermore, you exclude 25 msec of data
> at the end of the epoch that does belong in the epoch.
>
> Best Wishes
>
> Lau
> _______________________________________________
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>
>
> The information in this e-mail is intended only for the person to whom it
> is
> addressed. If you believe this e-mail was sent to you in error and the
> e-mail
> contains patient information, please contact the Partners Compliance
> HelpLine at
> http://www.partners.org/complianceline . If the e-mail was sent to you in
> error
> but does not contain patient information, please contact the sender and
> properly
> dispose of the e-mail.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20140429/b4a648b0/attachment.html 


More information about the Mne_analysis mailing list