<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 style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
Dear community,<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<br>
I am trying to save epoched data that is stored in .mat file as .edf using ft_write_data. For example, one of my .mat files has 1713 trials with 651 datapoints in each trial amounting to 1713 * 651 = 1115163 columns in total. I use the following code to concatenate
data of these trials and save it as .edf file.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<i>mat_data = load(mat_file_name);</i>
<div><i>filehdr = ft_fetch_header(mat_data.data);</i></div>
<div><i>concat_data = cat(2,mat_data.data.trial{:});</i></div>
<i>ft_write_data(edf_file_name , concat_data, 'header', filehdr);</i><br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
<i><br>
</i></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255);">
I get a .edf file which has only 1115000 columns. Similarly, in another case, original file has <span style="color: rgb(0, 0, 0); font-family: Calibri, Arial, Helvetica, sans-serif; background-color: rgb(255, 255, 255); display: inline !important;">1257081
columns but the generated .edf file has only 1257000 columns.<br>
<br>
Could anyone please tell what could be causing this to happen?<br>
<br>
Thanks and regards,<br>
Akshi<br>
IIIT-Bangalore, India</span></div>
</body>
</html>