<div dir="ltr">Hi Stephen,<div><br></div><div>Thank you for your response. I write something wrong in my previous email. the freq structure does have trails information. but then I do a source reconstruction and generate a source structure. phase locking value is calculated from the source structure directly. However, the source structure does not have any trails info (trails seems have been averaged).</div><div><br></div><div>source = ft_sourceanalysis(cfg, freq);</div><div>...</div><div>plv = ft_connectivityanalysis(cfg, souceSparse);</div><div><br></div><div><br></div><div>below are the freq structure generated by freq analysis, source structure generated by source analysis as well as the .avg field of source structure.</div><div><br></div><div><br></div><div><img src="cid:ii_16153c4d925092f4" alt="Inline images 1" width="314" height="184" style="margin-right: 0px;"><img src="cid:ii_16153c69947c23c4" alt="Inline images 2" width="245" height="183" style="margin-right: 0px;"><img src="cid:ii_16153c95327ecf63" alt="Inline images 3" width="240" height="183" style="margin-right: 0px;"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On 1 February 2018 at 18:02, Stephen Whitmarsh <span dir="ltr"><<a href="mailto:stephen.whitmarsh@gmail.com" target="_blank">stephen.whitmarsh@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Dear <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Yaocong,</span><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="font-size:12.8px">To understand your question, it would be helpful if you post the output of the freqanalysis, i.e. your <i>freq </i>datastructure. It should contain a .<i>pow </i>field, which should be an array of structs, numbering your number of trials, right?</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Cheers,</span></div><div><span style="font-size:12.8px">Stephen</span></div></div><div id="m_6562418138207874494DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2"><br>
<table style="border-top:1px solid #d3d4de">
        <tbody><tr>
        <td style="width:55px;padding-top:13px"><a href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=icon" target="_blank"><img src="https://ipmcdn.avast.com/images/icons/icon-envelope-tick-round-orange-animated-no-repeat-v1.gif" alt="" width="46" height="29" style="width:46px;height:29px"></a></td>
                <td style="width:470px;padding-top:12px;color:#41424e;font-size:13px;font-family:Arial,Helvetica,sans-serif;line-height:18px">Virus-free. <a href="https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail&utm_term=link" style="color:#4453ea" target="_blank">www.avast.com</a>
                </td>
        </tr>
</tbody></table><a href="#m_6562418138207874494_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2" width="1" height="1"></a></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On 1 February 2018 at 18:31, Yaocong Duan <span dir="ltr"><<a href="mailto:yaocong.duan@gmail.com" target="_blank">yaocong.duan@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><p class="MsoNormal" style="margin:0in 0in 0.0001pt;font-size:12pt;font-family:Calibri,sans-serif;color:rgb(0,0,0);font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-size:11pt">Hi All,<span></span></span></p><p class="MsoNormal" style="margin:0in 0in 0.0001pt;font-size:12pt;font-family:Calibri,sans-serif;color:rgb(0,0,0);font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-size:11pt"><span> </span></span></p><p class="MsoNormal" style="margin:0in 0in 0.0001pt;font-size:12pt;font-family:Calibri,sans-serif;color:rgb(0,0,0);font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-size:11pt">I am using Phase Locking Value to measure the connectivity between brain regions at the source level. I learned that the PLV is an average value over trails. In the fieldtrip code, I calculated a frequency model first, then do connectivity analysis with this freq model. The problem is I don’t see trails information in the freq model. So how do I get that phase locking result?<span></span></span></p><p class="MsoNormal" style="margin:0in 0in 0.0001pt;font-size:12pt;font-family:Calibri,sans-serif;color:rgb(0,0,0);font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-size:11pt"><span> </span></span></p><p class="MsoNormal" style="margin:0in 0in 0.0001pt;font-size:12pt;font-family:Calibri,sans-serif;color:rgb(0,0,0);font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-size:11pt">Below is my code. This code works, but I am confused about the question above.</span></p><br><div><img src="cid:ii_161526bd3b49d7bb" alt="Inline images 1" width="533" height="450"><br></div><div><br></div><div>Thanks in advance,</div><div>Yaocong</div></div>
<br></div></div>______________________________<wbr>_________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl" target="_blank">fieldtrip@donders.ru.nl</a><br>
<a href="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip" rel="noreferrer" target="_blank">https://mailman.science.ru.nl/<wbr>mailman/listinfo/fieldtrip</a><br></blockquote></div><br></div>
<br>______________________________<wbr>_________________<br>
fieldtrip mailing list<br>
<a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a><br>
<a href="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip" rel="noreferrer" target="_blank">https://mailman.science.ru.nl/<wbr>mailman/listinfo/fieldtrip</a><br></blockquote></div><br></div>