<html>
<body>
Hi,<br><br>
In the freqanalysis_wltconvol.m function, the FFT of zero-padded eeg or
MEG data and the FFT of the wavelets at various frequencies of interest
are convolved and the inverse FFT of that result is used to calculate
power in this manner on line 283:<br>
powdum <font face="Courier New, Courier">= (2.*
abs(autspctrmacttap)  ./ data.fsample) .^ 2;<br>
</font><font face="Arial, Helvetica" size=4>here, autspctrmacttap
corresponds to the complex output from the call to ifft.  <br>
</font>In previous e-mail Jan-Mathijs has mentioned that the abs of the
complex data gets you amplitude, so I am wondering why it gets multiplied
by 2 and divided by the sampling rate before being squared since power =
amplitude^2.  I am wondering how important it is to multiply by 2
and divide by the AD rate because I would like to take this complex
output and use it to calculate phase-locking factor, but I am not sure
what parts of the power transformation need to be removed - just the
abs() and the squaring?  Clarification of this line of code would be
extremely helpful to me.<br><br>
Thanks,<br>
Brian</body>
<br>
</html>