<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Hello FieldTrip community,<div><br></div><div>When I run ft_resampledata, I get the following error:</div><div><br></div><div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Error using signal.internal.resample.nonUniformParser>getSamples<br>The number of elements of Tx must match the number of rows of X when X is a matrix<br>Error in signal.internal.resample.nonUniformParser (line 23)<br>[x, tx] = getSamples(xIn,tx1,Dim);<br>Error in resample>nonUniformResample (line 268)<br>[x, tx, tGrid, fs, p, q] = signal.internal.resample.nonUniformParser(isDimValSet,Dim,m,xIn,varargin{:});<br>Error in resample (line 214)<br>            nonUniformResample(isDimValSet,Dim, m, method1, dimIn, xIn, ...<br>Error in ft_resampledata (line 253)<br>        newdat = transpose(resample(transpose(olddat),fsres,fsorig));</blockquote><div><br></div><div>I searched the mailing list and found a similar error from another user: <a href="https://mailman.science.ru.nl/pipermail/fieldtrip/2020-June/040130.html">[FieldTrip] Errors with downsampling and artifact rejection (ru.nl)</a></div></div><div><br></div><div>The solution for him was using an integer division of the original sampling rate (1000 -> 250 or 200). However, my data has a sampling rate of  508.6275 (HCP-MEG data, rmegpreproc output) which I'm afraid doesn't have a nice integer division. I tried with a couple of different cfg.resamplerefs but none of them worked.</div><div><br></div><div>My second question is a more general one. For memory-efficient processing, which one is a better option: using single data type or downsampling but keeping it double precision.</div><div><br></div><div>Thanks,</div><div>Yasir</div><div><br></div><div><br></div></div></div></div></div>