[Eeglablist] newtimef baselining
Arnaud Delorme
arno at ucsd.edu
Fri May 20 11:32:40 PDT 2011
Dear Chris,
the average baseline computed in newtimef is indeed performed before the log transformation. However, we divide the trial values by the baseline power, so the average baseline before log transformation is 1. Then transforming to the log, the average baseline can slightly off 0. Consider signal a
a = rand(1,10);
Then the baseline period is value 1 to 3
b = a./mean(a(1:3));
then we take the log
c1 = log10(b)
which is equivalent to
c2 = log10(a) - log10(mean(a(1:3)))
However,
mean(c1(1:3)) is not equal to 0. Log is used mostly for visualization in this case (although it is useful for making the data more normal if you are doing parametric statistics). The important is that the average baseline before taking the log is 1. mean(b(1:3)) = 1. If you do not take the log, you can visualize your data in % of baseline (this is possible in newtimef).
I guess if we really wanted to have the baseline exactly to 0 with the log, we would have to compute
c3 = log10(a) - (log10(a(1))+log10(a(2))+log10(a(3)))/3
I have not heard of this formulation though. It might be more rigorous when using parametric statistics because the baseline is strictly 0. Could someone expert in parametric testing comment on that?
Thanks,
Arno
On May 3, 2011, at 11:53 AM, Chris Bishop wrote:
> Hello,
>
> I'm a relatively new user to EEGLAB and have what looks like an error in thew 'newtimef' function, but it's so glaring that I can't help but believe that I have a fundamental misunderstanding of what the function newtimef function is supposed to do.
>
> I'm using eeglab7.2.9.20b.
>
> I'm trying to perform spectrotemporal decompositions on single trials. Strangely, the pre-stimulus period used for the baseline has a non-zero mean after returning from newtimef. For instance, if you place a break point at line 2005, you'll notice that the value removed from Pout (Pout = Pout - 10*repmat(log10(mbase),[1 length(timesout)]);) leads to a non-zero baseline in Pout (Pout(:,baseln)~=0). It's off by several dB for most trials. I think this might be because the averaging used to create mbase, the power of the baseline period, is done BEFORE the log transformation into decibels rather than after. So, the baseline period of Pout and the mean of mbase are not the same.
>
> Has anyone else experienced this issue? Am I just missing something? I apologize if I'm making some silly mistake ...
>
> Thanks,
> -Chris
> _______________________________________________
> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
> To unsubscribe, send an empty email to eeglablist-unsubscribe at sccn.ucsd.edu
> For digest mode, send an email with the subject "set digest mime" to eeglablist-request at sccn.ucsd.edu
More information about the eeglablist
mailing list