[FieldTrip] Calculate amplitudes and latencies

Julian Keil julian.keil at gmail.com
Sun Oct 7 15:24:02 CEST 2012


Hi,

I suppose your "peakdetect2" is located in the "private" folder. Matlab by default does not include private folders in the path. You can either rename it (e.g. to "notprivate") or manually copy the function to another folder.
The "findpeaks" should actually be a built-in function, but maybe you have to check the math works file exchange.

As usual, if you are not sure, if you have the respective function in your matlab path, check with "which".

Best,

Julian

Am 07.10.2012 um 13:23 schrieb Daria Laptinskaya:

> Hi Julian,
> 
> by using the peakdetect2- or the findpeaks-function I get an error: 
> ??? Undefined function or method 'peakdetect2' for input arguments of type 'double'
> (I use EGI-data with 149 channels and 113 timepoints).
> 
> Do you have any idea, what the problem could be?
> 
> Daria
> 
> 
> 
> 
> 
> 
> 2012/10/6 Daria Laptinskaya <daria.laptinskaya at googlemail.com>
> Many thanks-I will try to do!
> 
> Best,
> Daria
> 
> 
> 
> 2012/10/5 Julian Keil <julian.keil at gmail.com>
> Hi Daria,
> 
> you can either use the function "min" or "max" to find the minima and maxima in your data, or you can use the "peakdetect2"-function that can be found in the "private" folder of field trip.
> Another function, that is quite similar to the field trip-function is the "findpeaks"-function, in which you can even set parameters how exactly you want to define your peaks.
> Fo the latency: all the above functions can give you the index (i.e. sample point) of your peak, if you then compare this to your time-vector, you can get the latency until the maximum.
> 
> Good Luck,
> 
> Julian
> 
> Am 05.10.2012 um 17:10 schrieb Daria Laptinskaya:
> 
> > Dear fieldtrippers,
> >
> > does anyone know how I can find the peak maximum of an erp?
> > And how to calculate the latency until the maximum?
> >
> > Timelockanalysis and the grand average of all erps are already done.
> >
> > Best,
> > Daria
> >
> >
> > _______________________________________________
> > fieldtrip mailing list
> > fieldtrip at donders.ru.nl
> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> 
> 
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> 
> 
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20121007/61a02297/attachment.html>


More information about the fieldtrip mailing list