<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">
Hi Camilo,
<div><br>
</div>
<div>Have you recently updated your fieldtrip version? I think that the mexmaca64 compiled code was added a while back (w.r.t. the spm_bwlabel function it seems that this has been added about 8 months ago, as far as I can see in the repo’s history on github).</div>
<div><br>
</div>
<div>Best wishes,</div>
<div>Jan-Mathijs</div>
<div><br>
</div>
<div><br id="lineBreakAtBeginningOfMessage">
<div><br>
<blockquote type="cite">
<div>On 7 Oct 2024, at 17:11, Camilo Castelblanco Riveros via fieldtrip <fieldtrip@science.ru.nl> wrote:</div>
<br class="Apple-interchange-newline">
<div>
<div dir="ltr">
<div class="gmail_default" style="font-family:georgia,serif">Hi!</div>
<div class="gmail_default" style="font-family:georgia,serif"><br>
</div>
<div class="gmail_default" style="font-family:georgia,serif">Thanks in advance for your support.</div>
<div class="gmail_default" style="font-family:georgia,serif"><br>
</div>
<div class="gmail_default" style="font-family:georgia,serif"><b>Context</b>:</div>
<div class="gmail_default" style="font-family:georgia,serif">I am trying to run "ft_freqstatistics" comparing conditions within an individual subject. </div>
<div class="gmail_default" style="font-family:georgia,serif"><b>Issue</b>:</div>
<div class="gmail_default" style="font-family:georgia,serif">When running the code, I get the following error:</div>
<div class="gmail_default" style="font-family:georgia,serif">---</div>
<div class="gmail_default" style="font-family:georgia,serif">generated 1000 random permutations<br>
computing a parametric threshold for clustering<br>
computing statistic<br>
estimated time per randomization is 0.13 seconds<br>
computing statistic 1000 from 1000<br>
<br>
Error using spm_bwlabel (line 27)<br>
spm_bwlabel.c not compiled - see Makefile<br>
</div>
<div class="gmail_default" style="font-family:georgia,serif">---</div>
<div class="gmail_default" style="font-family:georgia,serif"><br>
</div>
<div class="gmail_default" style="font-family:georgia,serif"><b>Troubleshooting</b>:</div>
<div class="gmail_default" style="font-family:georgia,serif">1. I inspected my fieldtrip SPM toolbox (''...GitHub/fieldtrip/external/spm12'') has the spm_bwlabel files but not the spm_bwlabel.mexmaca64. I think I need the spm_bwlabel.mexmaca64 to run it on
 my machine; is that correct?</div>
<div class="gmail_default" style="font-family:georgia,serif">2. Doing some reading, I may need to compile the spm_make_standalone.m file. However, I do not know how to do it in Fieldtrip's path.</div>
<div class="gmail_default" style="font-family:georgia,serif"><br>
</div>
<div class="gmail_default" style="font-family:georgia,serif"><b>My code</b>:</div>
<div class="gmail_default" style="font-family:georgia,serif">
<div class="gmail-rtcContent" style="padding:30px">
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg = [];</span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.parameter = <span style="color:rgb(167,9,245)">
'powspctrm'</span>; <span style="color:rgb(0,128,19)">% Specify power spectrum parameter</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.method = <span style="color:rgb(167,9,245)">'montecarlo'</span>;
<span style="color:rgb(0,128,19)">% Use permutation testing</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.statistic = <span style="color:rgb(167,9,245)">
'depsamplesT'</span>; <span style="color:rgb(0,128,19)">% Dependent samples t-test</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.correctm = <span style="color:rgb(167,9,245)">'cluster'</span>;
<span style="color:rgb(0,128,19)">% Use cluster-based correction</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.clusteralpha = 0.05; <span style="color:rgb(0,128,19)">
% Threshold for forming clusters</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.clusterstatistic = <span style="color:rgb(167,9,245)">
'maxsum'</span>; <span style="color:rgb(0,128,19)">% Sum of t-values for defining clusters</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.alpha = 0.025; <span style="color:rgb(0,128,19)">
% Significance level for two-tailed test</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.tail = 0; <span style="color:rgb(0,128,19)">% Two-tailed test</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.clustertail = 0; <span style="color:rgb(0,128,19)">
% Two-tailed cluster statistics</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.numrandomization = 1000; <span style="color:rgb(0,128,19)">
% Number of random permutation</span></span><span style="white-space:pre">cfg.neighbours = [];
</span><span style="white-space:pre;color:rgb(0,128,19)">% No neighborhood structure needed for iEEG</span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
</div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre"><span style="color:rgb(0,128,19)">% Design matrix </span>
</span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">design = zeros(2, ntrials_low + ntrials_high);</span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">design(1, 1:ntrials_low) = 1; <span style="color:rgb(0,128,19)">
% Assign label 1 to trials in the low condition</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">design(1, ntrials_low+1:end) = 2; <span style="color:rgb(0,128,19)">
% Assign label 2 to trials in the high condition</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">design(2, :) = [1:ntrials_low, 1:ntrials_high]; <span style="color:rgb(0,128,19)">
% Assign trial indices</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
</div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre"></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.design = design;</span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.uvar = 2; <span style="color:rgb(0,128,19)">% unit of observation (subject)</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre">cfg.ivar = 1; <span style="color:rgb(0,128,19)">% independent variable (condition)</span></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre"></span></div>
<div class="gmail-lineNode" style="font-size:13px;font-family:Menlo,Monaco,Consolas,"Courier New",monospace">
<span style="white-space:pre"><span style="color:rgb(0,128,19)">%7 Compute statistics</span></span><span style="white-space:pre">[stat] = ft_freqstatistics(cfg, TFR_low, TFR_high);</span></div>
</div>
</div>
<div class="gmail_default" style="font-family:georgia,serif"><br>
</div>
<div class="gmail_default" style="font-family:georgia,serif">With gratitude,<br>
Camilo</div>
<div>
<div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">
<div><b style="color:rgb(80,0,80)"><span style="font-size:12pt;color:rgb(99,144,68)"><font face="georgia, serif">================================</font></span></b><font face="georgia, serif"><b><br>
</b></font></div>
<div><font face="georgia, serif" color="#38761d"><b>Camilo Castelblanco Riveros (He/His)</b></font></div>
<div><font face="georgia, serif" color="#274e13">Ph.D. Candidate (G3)</font></div>
<div>
<div><font face="georgia, serif" color="#274e13"><a href="https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.robertsonlab.com%2F&data=05%7C02%7Cfieldtrip%40science.ru.nl%7C689e2bbe8b2a4e7b373808dce6e77d1b%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638639129107208886%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=pHDWUonF5qTutMW5B2E2cy%2BhD0cnN2B0BbRWl7qSMKM%3D&reserved=0" originalsrc="https://www.robertsonlab.com/" shash="MsKuVEyiIFfaNsJ062v9fSmLZh82eI6IiEHzSbZmm3za0TOcgIQPF30s+1RIuH1UAPdZ6idODGS1Xuk2nr4RxvTDxwKmLZy0LYtsUeoSoieLME1ZIfTGTMeQ+ZKw2e1/EeOjEOahho1mqFxRWtQ9niLtGB3KR0SrUR5sVRSe4WU=" originalsrc="https://www.robertsonlab.com/" shash="WvDHsLeBCnPANCJyRNXykvnF4UbRd9skvzP0Dwojd3hIRnmMJTeI4KcpMgBEhTx5/ke3mPpLw2a0aU7JabG+P0iDUO4idKJMN/eCdr4LK/sS+YJwSYpM2mASCy2isdmT+o0Ey4FUW8pcywW4msdiN9qoR4S+eBY+yVKROVpa+4o=" target="_blank">Robertson
 Lab</a> & <a href="https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.dartmouth-hitchcock.org%2Fresearch%2Fsearch-clinical-trials%2Ftrial%2FSTUDY02001606&data=05%7C02%7Cfieldtrip%40science.ru.nl%7C689e2bbe8b2a4e7b373808dce6e77d1b%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638639129107208886%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=AnoD7GVYaK8TiABT0eTlUgdnq%2BSb7MbtdnJCj2mPvDI%3D&reserved=0" originalsrc="https://www.dartmouth-hitchcock.org/research/search-clinical-trials/trial/STUDY02001606" shash="CR44w7sKcwUveS+g8sDx1gylTAHNKPo/HRwoOUvlAqStn+2eg7VBFVeI7HwRfIlukHZc3EkplaNV5cufIGsyRsleO5w5zfSDbah4JRzuEKJpyyvOt/+np17VKSfSL/xK4fkcYoXVVOH0Wpu/DDcVrPJzub7w2WUg57bQLodHAbA=" originalsrc="https://www.dartmouth-hitchcock.org/research/search-clinical-trials/trial/STUDY02001606" shash="PgBA44TBpvLE2KarWvjNXob9+7c65hAhaal0AG+2k+H+2B60GdgsDn8Zt/R0hqRtYI/UodC6qkZ07ZVjppKOcjo2Z0u84ByO1rgKaS5xBiFCSGl0W+atWSCVAkdjQbQ5heBohtz5wVohLAbAYEZZYjH1G2dIwDmaDzhDk8G/1rc=" target="_blank">
Bujarski Lab</a></font></div>
<div><font face="georgia, serif" color="#274e13">Student Interest Group in Neurology (<a href="https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgeiselmed.dartmouth.edu%2Fstudent-gov%2Fstudent-groups%2F&data=05%7C02%7Cfieldtrip%40science.ru.nl%7C689e2bbe8b2a4e7b373808dce6e77d1b%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638639129107208886%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=anr%2BehaNtQCMvlUH69j7SI8AwG7AGnEJ9SXsLCJh8mI%3D&reserved=0" originalsrc="https://geiselmed.dartmouth.edu/student-gov/student-groups/" shash="SZnTX3kFIRGU2ti0+PoF30gHYIEeHizdJJVoZJ8OQHTjP5xfMK2Obkgmn40oNAr2UFVQ2qTcRAPXruDkzEKEyKWFwNfjVZu7TaMuhWjspE+Z6MU+bk+UHCA7dNZVccNYvg/oyu/UlmME4YPOMT528QybXZW88L2gPaqgaIysqJQ=" originalsrc="https://geiselmed.dartmouth.edu/student-gov/student-groups/" shash="yfrN0PpbwGUm5Qp/USQvuQjf7FTG7L5xDNcNpVbH8gfTm0VxSRKYnp5siqWiC9bnR8IRNJ2i5x8BHMqOf0iCwsO3C8X0QrUVkdDebG5v0ndqOChj5teIaQ+SnLAHQlK1yfzq9nA5rueWgyiUfNMlHSwFeYsMCmquHlsCuDSQzCg=" target="_blank">SIGN</a>)
 Co-Leader<u></u></font></div>
</div>
<div><font face="georgia, serif" color="#274e13">Diversity Student Advisory Board Member</font></div>
<div><font face="georgia, serif" color="#274e13">e: <a href="mailto:camilo.a.castelblanco.riveros.gr@dartmouth.edu" target="_blank">ccastelblanco.gr@dartmouth.edu</a></font></div>
<div><font face="georgia, serif" color="#274e13"><a href="https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdartmouth.zoom.us%2Fmy%2Fccastelblanco&data=05%7C02%7Cfieldtrip%40science.ru.nl%7C689e2bbe8b2a4e7b373808dce6e77d1b%7C084578d9400d4a5aa7c7e76ca47af400%7C1%7C0%7C638639129107208886%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=%2BHu5cOQxh9MnoG2TRuQhZfVnNPAv6ThPfUvp4RyNLYc%3D&reserved=0" originalsrc="https://dartmouth.zoom.us/my/ccastelblanco" shash="wU2u4xjRc0tSxOUbk6PRatFFC3+v/gQt5WZmeNIglDrVzcvfZKWODxnSKzmQDxe15P9osh6UtHuEL1CRSCcqRhr6yBgR2FTlnjS0lAcVQCai+g8IPF+UXe+npa50c1byq5l4cPyfTDOoXAUX4c2rflf7yevK2DJpDp4sJ8FmBM8=" originalsrc="https://dartmouth.zoom.us/my/ccastelblanco" shash="Lkqr2uqHLJ/lzZjpCxV0HuC+jtzUbLDempGQiZvh8+p9orNbdBxYHKeeUfjhl60oX3WY9Ol+htebYWtfer7Nd4OkeEUArbh+b4SWZrsWpcvxKSF/QM3MhvAS+4EYN6iL0q/b6lJCtHFCt2NL8YDjFGeAVuNR2In+2fC4ROuQuTc=" target="_blank">Zoom</a></font></div>
<div>
<div style="color:rgb(34,34,34)">
<div><font face="georgia, serif"><br>
</font></div>
</div>
</div>
<div><font face="georgia, serif"><img src="https://pbs.twimg.com/profile_images/1442874308360032261/L7MnNrBk_400x400.jpg" alt="Integrative Neuroscience at Dartmouth (IND) (@DartmouthNeuro) / Twitter" width="96" height="96"><img src="https://jobsearch.dartmouth-hitchcock.org/wp-content/uploads/DH-Bug-e1666020448423.png" width="96" height="96"></font></div>
</div>
</div>
</div>
</div>
_______________________________________________<br>
fieldtrip mailing list<br>
https://mailman.science.ru.nl/mailman/listinfo/fieldtrip<br>
https://doi.org/10.1371/journal.pcbi.1002202<br>
</div>
</blockquote>
</div>
<br>
</div>
</body>
</html>