<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" id="owaParaStyle"></style><style type="text/css"></style>
</head>
<body fpstyle="1" ocsi="0">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;"><span style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">Hi everyone,</span>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
For my experiment I have three MEG sessions. For analysis I preprocessed them and combined them using ft_appenddata. However, the 'grad' field in the data structured is then removed. When I call ft_megplanar (see code) to do time frequency analysis I get the
following error (matlab2013a in cluster, latest fieldtrip version):</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
------------------------------<wbr>----</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<div>cfg = [];</div>
<div>cfg.method = 'template';</div>
<div>cfg.template = 'CTF275_neighb.mat';</div>
<div>% neighbours = ft_prepare_neighbours(cfg, alldatacorrect);</div>
<div>neighbours = ft_prepare_neighbours(cfg, alldata);</div>
<div><br>
</div>
<div>cfg = [];</div>
<div>cfg.method = 'sincos';</div>
<div>cfg.neighbours = neighbours;</div>
<div>% data_planar_correct = ft_megplanar(cfg, alldatacorrect);</div>
<div>data_planar = ft_megplanar(cfg, alldata);</div>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
------------------------------<wbr>----<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<div><i>Error using ft_checkdata (line 527)</i></div>
<div><i>This function requires MEG data with a 'grad' field</i></div>
<div><i><br>
</i></div>
<div><i>Error in ft_megplanar (line 96)</i></div>
<div><i>data = ft_checkdata(data, 'datatype', {'raw' 'freq'}, 'feedback', 'yes', 'hassampleinfo', 'yes', 'ismeg', 'yes', 'senstype', {'ctf151', 'ctf275', 'bti148',</i></div>
<div><i>'bti248', 'itab153', 'yokogawa160', 'yokoga </i></div>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
I already looked at the 'grad' field of the individual sessions and they are not the same. How should I solve this?</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
Thanks for your help,</div>
<div style="color: rgb(34, 34, 34); font-family: arial, sans-serif; font-size: 12.8000001907349px; background-color: rgb(255, 255, 255);">
Mats</div>
</div>
</body>
</html>