<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
</head>
<body dir="auto">
<div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;">Hey </span><span style="-webkit-text-size-adjust: auto; background-color: rgba(255, 255, 255, 0);">Praghajieeth,</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto; background-color: rgba(255, 255, 255, 0);"><br>
</span></div>
<div><span style="-webkit-text-size-adjust: auto;">Firstly, I am by no means an expert of fieldtrip (I only started using it six or so months ago), so if I am wrong I apologise but you have been warned haha.</span></div>
<div><span style="-webkit-text-size-adjust: auto;"><br>
</span></div>
<div><span style="-webkit-text-size-adjust: auto;">Ill try and help, can you look up the following:</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;">Can you tell me what the dimensions of Cy is and whether there are any NaNs.</span></div>
<div><span style="-webkit-text-size-adjust: auto;">What dimensions are data.chan.elec and data.label?</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;">Also its worth checking your vol1.mat for NaNs aswell.</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;"><br>
</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;">Good luck!</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;"><br>
</span></div>
<div style="-webkit-text-size-adjust: none;"><span style="-webkit-text-size-adjust: auto;">Tyler</span></div>
<br>
<span style="-webkit-text-size-adjust: auto;">Sent from my iPad</span></div>
<div style="-webkit-text-size-adjust: auto;"><br>
On 27 Aug 2014, at 8:33 pm, "Praghajieeth Raajhen" <<a href="mailto:praajhen@gmail.com">praajhen@gmail.com</a>> wrote:<br>
<br>
</div>
<blockquote type="cite" style="-webkit-text-size-adjust: auto;">
<div>
<div dir="ltr">Hello!!!!
<div><br>
</div>
<div>Please Help out. where am I going wrong?</div>
<div><br>
</div>
<div>
<div> cfg = [];</div>
<div> cfg.channel = 'EEG';</div>
<div> cfg.method = 'sam';</div>
<div> cfg.grid = grid;</div>
<div> cfg.vol = vol1;</div>
<div> cfg.projectnoise = 'yes';</div>
<div> cfg.keepfilter = 'yes';</div>
<div> source = ft_sourceanalysis( cfg, timelock);</div>
</div>
<div><br>
</div>
<div>workspace of grid,vol1,timelock (.mat)</div>
<div><a href="https://www.dropbox.com/s/bu1inxwgeyc01mi/timelock%2Cgrid%2Cvol.mat?dl=0">https://www.dropbox.com/s/bu1inxwgeyc01mi/timelock%2Cgrid%2Cvol.mat?dl=0</a><br>
</div>
<div><br>
</div>
<div>1. Using fieldtrip 2013 version</div>
<div>When i do EEG sourceanalysis using "SAM" method, following error occurs</div>
<div><br>
</div>
<div>
<div><font color="#ff0000">Attempted to access noise(0); index must be a positive integer or logical.</font></div>
<div><br>
</div>
<div><font color="#ff0000">Error in ==> beamformer_sam at 111</font></div>
<div><font color="#ff0000"> noise = noise(end);</font></div>
<div><font color="#ff0000"><br>
</font></div>
<div><font color="#ff0000">Error in ==> ft_sourceanalysis at 841</font></div>
<div><font color="#ff0000"> dip(i) = beamformer_sam(grid, sens, vol, squeeze_avg,squeeze(Cy(i,:,:)), optarg{:});</font></div>
</div>
<div><font color="#ff0000"><br>
</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">PS: same code for MEG source reconsturction works quite good.</font></div>
<div><font color="#000000"><br>
</font></div>
<div><font color="#000000">2. Using fieldtrip 2014 version</font></div>
<div><font color="#000000">when i do the same I'm getting this kind of errors</font></div>
<div><font color="#000000"><br>
</font></div>
<div>
<div><font color="#ff0000">Undefined function or variable 'abort'.</font></div>
<div><font color="#ff0000"><br>
</font></div>
<div><font color="#ff0000">Error in ==> ft_sourceanalysis at 156</font></div>
<div><font color="#ff0000">if abort</font></div>
</div>
<div><font color="#ff0000"><br>
</font></div>
<div>PS: Moreover, I cant even do preprocessing with 2014 fieldtrip version. It is showing same above error. </div>
<div><br>
</div>
<div><br>
</div>
<div>advance thanks for your kind help.</div>
<div><br>
</div>
<div>Praghajith R.S.</div>
<div><a href="mailto:praajhen@gmail.com">praajhen@gmail.com</a></div>
<div>Master Thesis @ UKSH</div>
<div>Kiel, Germany</div>
<div><br>
</div>
<div><font color="#ff0000"><br>
</font></div>
</div>
</div>
</blockquote>
<blockquote type="cite" style="-webkit-text-size-adjust: auto;">
<div><span>_______________________________________________</span><br>
<span>fieldtrip mailing list</span><br>
<span><a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a></span><br>
<span><a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a></span></div>
</blockquote>
</body>
</html>