<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html; charset=ISO-8859-1"
 http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Karl,<br>
<br>
You can use wltconvol if you edit it.  If you step through the code,
and find the spot where data are converted form complex numbers to
power values, you only need to remove the abs(***) statement to keep
the data in complex form.  This is how we've done it, but you may have
a different version of the code:<br>
<br>
if keep == 1<br>
            powdum = (2.* abs(autspctrmacttap)  ./ data.fsample) .^ 2;<br>
        elseif keep == 2<br>
            %this is where we retain complex values:<br>
            powdum = (autspctrmacttap  ./ data.fsample);<br>
        end<br>
<br>
<br>
Hope this helps,<br>
Brian<br>
On 3/10/2010 10:28 AM, Karl Doron wrote:
<blockquote
 cite="mid:1fc4dff91003101028i5460461bn63c1d9edb8fad448@mail.gmail.com"
 type="cite">Hello Jan-Mathijs,<br>
  <br>
I'm able to find the complex trial data now, but I've been avoiding the
mtmconvol method because I don't have very good grasp on it. I'm
getting phase angles greater than pi. Is there a simple way to run it
on some simulated data? <br>
  <br>
I'm trying to find a periodic signal at 2Hz with non-stationary gamma
transients linked to its phase.<br>
  <br>
Thanks for any feedback!<br>
  <br>
-karl<br>
  <br>
  <div class="gmail_quote">On Wed, Mar 10, 2010 at 3:32 PM, jan-mathijs
schoffelen <span dir="ltr"><<a moz-do-not-send="true"
 href="mailto:jan.schoffelen@donders.ru.nl">jan.schoffelen@donders.ru.nl</a>></span>
wrote:<br>
  <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi
Karl,<br>
    <br>
freqanalysis with method = 'mtmconvol' allows you to keep the fourier
coefficients (cfg.output = 'fourier') so you'll get a complex
representation there.<br>
    <br>
Best,<br>
    <br>
Jan-Mathijs
    <div>
    <div class="h5"><br>
    <br>
    <br>
On Mar 10, 2010, at 2:36 PM, Karl Doron wrote:<br>
    <br>
    <blockquote class="gmail_quote"
 style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello,<br>
      <br>
I'm looking at some MEG data and have a hypothesis about cross frequency<br>
coupling. Specifically, a relationship between lower frequency phase and<br>
higher frequency amplitudes. I'm trying to save and view the phase
angles<br>
after doing wavelet analysis using wltconvol.<br>
      <br>
If this is implemented -great! Otherwise, it seems that somewhere after
line<br>
216 of ft_freqanalysis_wltconvol.m (after the ifft), I should be able to<br>
save the complex numbers and use angle(input) to find the phase angle of<br>
each time point on a trial by trial basis. It seems easier to do in the<br>
'tfr' wavelet code, but the time domain covolution is very slow.<br>
      <br>
Thanks for any help!<br>
      <br>
Karl Doron<br>
      <br>
----------------------------------<br>
The aim of this list is to facilitate the discussion between users of
the FieldTrip  toolbox, to share experiences and to discuss new ideas
for MEG and EEG analysis. See also <a moz-do-not-send="true"
 href="http://listserv.surfnet.nl/archives/fieldtrip.html"
 target="_blank">http://listserv.surfnet.nl/archives/fieldtrip.html</a>
and <a moz-do-not-send="true"
 href="http://www.ru.nl/neuroimaging/fieldtrip" target="_blank">http://www.ru.nl/neuroimaging/fieldtrip</a>.<br>
      <br>
    </blockquote>
    <br>
    </div>
    </div>
Dr. J.M. (Jan-Mathijs) Schoffelen<br>
Donders Institute for Brain, Cognition and Behaviour,<br>
Centre for Cognitive Neuroimaging,<br>
Radboud University Nijmegen, The Netherlands<br>
    <a moz-do-not-send="true" href="mailto:J.Schoffelen@donders.ru.nl"
 target="_blank">J.Schoffelen@donders.ru.nl</a><br>
Telephone: 0031-24-3668063
    <div>
    <div class="h5"><br>
    <br>
----------------------------------<br>
The aim of this list is to facilitate the discussion between users of
the FieldTrip  toolbox, to share experiences and to discuss new ideas
for MEG and EEG analysis. See also <a moz-do-not-send="true"
 href="http://listserv.surfnet.nl/archives/fieldtrip.html"
 target="_blank">http://listserv.surfnet.nl/archives/fieldtrip.html</a>
and <a moz-do-not-send="true"
 href="http://www.ru.nl/neuroimaging/fieldtrip" target="_blank">http://www.ru.nl/neuroimaging/fieldtrip</a>.<br>
    </div>
    </div>
  </blockquote>
  </div>
  <br>
  <p>----------------------------------</p>
  <p>The aim of this list is to facilitate the discussion between users
of the FieldTrip toolbox, to share experiences and to discuss new ideas
for MEG and EEG analysis.</p>
  <p> <a class="moz-txt-link-freetext" href="http://listserv.surfnet.nl/archives/fieldtrip.html">http://listserv.surfnet.nl/archives/fieldtrip.html</a></p>
  <p> <a class="moz-txt-link-freetext" href="http://www.ru.nl/fcdonders/fieldtrip/">http://www.ru.nl/fcdonders/fieldtrip/</a></p>
</blockquote>
<br>
</body>
</html>
<p>----------------------------------</p>
<p>The aim of this list is to facilitate the discussion between users of the FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis.</p>
<p>  http://listserv.surfnet.nl/archives/fieldtrip.html</p>
<p>  http://www.ru.nl/fcdonders/fieldtrip/</p>