<div dir="ltr"><div style>Dear <span style="color:rgb(136,136,136);font-family:arial,sans-serif;font-size:12.666666984558105px">Nenad</span></div>please use repmat evoked.powspctrm(3-D matrix) to match dimension of epochs in total.powspctrm(4-D matrix). Some thing like this<div>
<br><div><div>TF_mean=repmat(evoked.powspctrm,[ 1 1 1 nEpochs]);</div><div>TF_mean=permute(TF_mean,[4 1 2 3]);</div><div>TF_induced=total.powspctrm-TF_mean;</div><div>Induced=(squeeze(mean(abs(TF_induced))));</div><div><br>
</div><div style><b>This will only work if you have complex TF matrices</b></div><div><br></div><div style>Sheraz</div><div style>Martinos Center</div><div><br></div><div><br></div><div><br></div><div>Induced=(squeeze(mean(abs(TF_induced))));</div>
</div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Jan 10, 2013 at 1:56 PM, Nenad Polomac <span dir="ltr"><<a href="mailto:polomacnenad@gmail.com" target="_blank">polomacnenad@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<div><br></div><div>I would like to calculate induced time frequency activity for my MEG data. I plan to do it as follows. First I calculate total time-frequency for every single trial. Second, I calculate evoked activity with ft_freqanalysis for the averaged ERF. Then I subtract evoked activity from every trial total activity. And finally I average these differences. I believe this is correct way... </div>


<div><br></div><div>My problem is how to subtract evoked.powspctrm(3-D matrix) from total.powspctrm(4-D matrix). </div><div><br></div><div>Thank you in advance!</div><span class="HOEnZb"><font color="#888888"><div><br></div>
<div>Nenad</div>
<div><br></div><div><br></div>
</font></span><br>_______________________________________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a><br>
<a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br></blockquote></div><br></div>