<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<div id="divtagdefaultwrapper" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;" dir="ltr">
<p style="margin-top:0;margin-bottom:0">Hi Jan-Mathjis,</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">What a relief and thank you very much!</p>
<br>
Cheers,</div>
<div id="divtagdefaultwrapper" style="font-size: 12pt; color: rgb(0, 0, 0); font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;" dir="ltr">
Jane<br>
<div style="color: rgb(0, 0, 0);">
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> fieldtrip <fieldtrip-bounces@science.ru.nl> on behalf of Schoffelen, J.M. (Jan Mathijs) <jan.schoffelen@donders.ru.nl><br>
<b>Sent:</b> Monday, 11 February 2019 3:39 PM<br>
<b>To:</b> FieldTrip discussion list<br>
<b>Subject:</b> Re: [FieldTrip] Is it normal to have NaNs in source analysis output?</font>
<div> </div>
</div>
<div class="" style="word-wrap:break-word">Hi Jane,
<div class=""><br class="">
</div>
<div class="">Yes, it is not a problem (and expected) for the outside-of-the-head dipole positions to be represented by NaNs.</div>
<div class=""><br class="">
</div>
<div class="">Best wishes and keep up the good work,</div>
<div class=""><br class="">
</div>
<div class="">Jan-Mathijs</div>
<div class=""><br class="">
</div>
<div class="">
<div class="">
<div class="" style="word-wrap:break-word">
<div class="" style="word-wrap:break-word">
<div class="" style="word-wrap:break-word">J.M.Schoffelen, MD PhD<br class="">
Senior Researcher, VIDI-fellow - PI, language in interaction<br class="">
Telephone: +31-24-3614793</div>
<div class="" style="word-wrap:break-word">Physical location: room 00.028</div>
<div class="" style="word-wrap:break-word">Donders Centre for Cognitive Neuroimaging, Nijmegen, The Netherlands<br class="">
<br class="">
<br class="">
</div>
</div>
</div>
</div>
<div class=""><br class="x_webkit-block-placeholder">
</div>
<div>
<blockquote type="cite" class="">
<div class="">On 11 Feb 2019, at 03:42, Jane Tan <<a href="mailto:Jane.Tan@murdoch.edu.au" class="OWAAutoLink" id="LPlnk70134" previewremoved="true">Jane.Tan@murdoch.edu.au</a>> wrote:</div>
<br class="x_Apple-interchange-newline">
<div class="">
<div id="x_divtagdefaultwrapper" dir="ltr" class="" style="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; font-size: 12pt; font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;">
<div class="" style="margin-top:0px; margin-bottom:0px">Dear Fieldtrippers,</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px">My name is Jane, and this is my first time posting a question to this community. First and foremost, I would like to apologise if my question is extremely trivial.</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px">I am trying to perform source analysis using the Beamformer DICS approach on EEG data. My data has been preprocessed using the EEGlab toolbox, and in this particular instance I am only interested in 20
Hz source space activity for time periods around event 'SS'.</div>
<div class="" style="margin-top:0px; margin-bottom:0px">My question is very simple: is it normal to get NaNs in the avg.pow output of the source analysis? It seems to make sense; positions in the grid that do not have 20 Hz reconstructed activity would be represented
by NaNs. However, I'm a novice (in all aspects: Matlab, EEG analysis, and Fieldtrip), and for a sanity check, would like to confirm that getting NaNs in my source output is normal.</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px">Here is the code I executed:</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<div class="">%% Loading data</div>
<div class="">
<div class="">[EEG] = pop_loadset('E:\preprocesseddata.set'); </div>
<div class="">EEG = pop_epoch( EEG, { 'SSstopDIN' }, [-0.5 0.8]); % Epoch to event of interest 'SS'</div>
<div class="">dataSS_epoched = eeglab2fieldtrip(EEG, 'preprocessing'); % Convert eeglab dataset to fieldtrip data</div>
<div class=""><br class="">
</div>
</div>
<br class="">
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<div class="">%% Calculating the cross spectral density matrix</div>
<div class=""><br class="">
</div>
<div class=""> cfg = [];</div>
<div class=""> cfg.method = 'mtmfft';</div>
<div class=""> cfg.taper = 'hanning';</div>
<div class=""> cfg.output = 'powandcsd';</div>
<div class=""> cfg.foi = 4:40;</div>
<div class=""> cfg.keeptrials = 'no';</div>
<div class=""> TFR_SS = ft_freqanalysis(cfg, dataSS_epoched);</div>
<br class="">
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<div class="">%% Computing leadfield </div>
<div class=""><br class="">
</div>
<div class="">cfg = [];</div>
<div class="">cfg.headmodel = vol; %using BEM head model from FT template</div>
<div class="">cfg.reducerank = 3; %default = 3 for EEG</div>
<div class="">cfg.elec = elec_aligned </div>
<div class="">cfg.grid.resolution = 0.5; % use a 3-D grid with a 0.5 cm resolution</div>
<div class="">cfg.grid.unit = 'cm';</div>
<div class="">[grid] = ft_prepare_leadfield(cfg);</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class="">%% Source analysis (without contrasts; just testing source reconstruction for one condition first)</div>
<div class=""><br class="">
</div>
<div class="">cfg = [];</div>
<div class="">cfg.method = 'dics';</div>
<div class="">cfg.frequency = 20; </div>
<div class="">cfg.grid = grid;</div>
<div class="">cfg.headmodel = vol;</div>
<div class="">cfg.elec = elec_aligned;</div>
<div class="">sourceSS_nocon = ft_sourceanalysis(cfg, TFR_SS); % Here, <span class="" style="font-family:Calibri,Helvetica,sans-serif,EmojiFont,'Apple Color Emoji','Segoe UI Emoji',NotoColorEmoji,'Segoe UI Symbol','Android Emoji',EmojiSymbols; font-size:16px">sourceSS_nocon.avg.pow
shows NaNs in some cells and not others</span></div>
<br class="">
<p class="" style="margin-top:0px; margin-bottom:0px"></p>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span id="x_cid:a458c15f-7cd8-4957-b19f-49686ec7517a"><pastedImage.png></span><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px">My sincere thanks in advance!</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div class="" style="margin-top:0px; margin-bottom:0px"><br class="">
</div>
<div id="x_Signature" class="">
<div id="x_divtagdefaultwrapper" dir="ltr" class="" style="font-size:12pt; font-family:Calibri,Helvetica,sans-serif,EmojiFont,'Apple Color Emoji','Segoe UI Emoji',NotoColorEmoji,'Segoe UI Symbol','Android Emoji',EmojiSymbols">
<div class="" style="font-family:Tahoma; font-size:13px">
<div class=""></div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span lang="EN-SG" class="">Best regards,</span></div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span lang="EN-SG" class=""><br class="">
</span></div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span lang="EN-SG" class="">Jane</span></div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span lang="EN-SG" class=""><br class="">
</span></div>
<div class="" style="margin-top:0px; margin-bottom:0px"><span lang="EN-SG" class=""><br class="">
</span></div>
<p class="x_MsoNormal" style="margin-top:0px; margin-bottom:5pt; line-height:normal; background-color:white; background-position:initial initial; background-repeat:initial initial">
<b class=""><span class="" style="font-size:9pt; font-family:Verdana,sans-serif">Jane Tan, PhD Candidate</span></b><span class="" style="font-size:11.5pt; font-family:'Segoe UI',sans-serif; color:rgb(33,33,33)"></span></p>
<p class="x_MsoNormal" style="margin-top:0px; margin-bottom:5pt; line-height:normal; background-color:white; background-position:initial initial; background-repeat:initial initial">
<b class=""><span class="" style="font-size:9pt; font-family:Verdana,sans-serif">School of Psychology and Exercise Science | Murdoch University</span></b><span class="" style="font-size:11.5pt; font-family:'Segoe UI',sans-serif; color:rgb(33,33,33)"></span></p>
<p class="x_MsoNormal" style="margin-top:0px; margin-bottom:5pt; line-height:normal; background-color:white; background-position:initial initial; background-repeat:initial initial">
<span class="" style="font-size:9pt; font-family:Verdana,sans-serif">Room 3.001 Social Science Building, 90 South Street, Murdoch WA 6150 <b class="">| </b>Email:<span class="x_Apple-converted-space"> </span><a href="mailto:Jane.Tan@murdoch.edu.au" class="OWAAutoLink" id="LPlnk146465" previewremoved="true">Jane.Tan@murdoch.edu.au</a></span><span class="" style="font-size:11.5pt; font-family:'Segoe UI',sans-serif; color:rgb(33,33,33)"></span></p>
<p class="x_MsoNormal" style="margin-top:0px; margin-bottom:5pt; line-height:normal; background-color:white; background-position:initial initial; background-repeat:initial initial">
<span id="x_cid:95c33115-83df-4674-9c4c-28935742fc23"><Outlook-3jowpkkg.png></span><br class="">
</p>
<div class=""></div>
</div>
</div>
</div>
</div>
<span class="" style="font-family:Helvetica; font-size:14px; 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; float:none; display:inline!important">_______________________________________________</span><br class="" style="font-family:Helvetica; font-size:14px; 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 class="" style="font-family:Helvetica; font-size:14px; 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; float:none; display:inline!important">fieldtrip
mailing list</span><br class="" style="font-family:Helvetica; font-size:14px; 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">
<a href="https://clicktime.symantec.com/3PxWcgg9pAUqfWN3Awe1wPB7Vc?u=https%3A%2F%2Fmailman.science.ru.nl%2Fmailman%2Flistinfo%2Ffieldtrip" class="OWAAutoLink" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px" id="LPlnk364579" previewremoved="true">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br class="" style="font-family:Helvetica; font-size:14px; 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">
<a href="https://clicktime.symantec.com/3TURgaEM3PFv2QqBMmF1AjP7Vc?u=https%3A%2F%2Fdoi.org%2F10.1371%2Fjournal.pcbi.1002202" class="OWAAutoLink" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px" id="LPlnk65225" previewremoved="true">https://doi.org/10.1371/journal.pcbi.1002202</a></div>
</blockquote>
</div>
<br class="">
</div>
<br class="">
<br class="">
<div class="">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<br class="">
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>