[FieldTrip] ft_rejectvisual reduces trial length

Eelke Spaak e.spaak at donders.ru.nl
Thu Nov 8 09:33:17 CET 2018


Hi Tineke,

That sounds like a bug to me. You could consider filing it:
https://github.com/fieldtrip/fieldtrip/issues

Meanwhile, as a workaround, I usually ensure that one of the columns
of my data.trialinfo contains unique trial identifiers (e.g.
data.trialinfo(:,end+1) = 1:numel(data.trial);). Then, after datclean
= ft_rejectvisual(cfg, data), the datclean.trialinfo(:,end) will
contain those trial IDs that are kept. Store those IDs somewhere and
then you can select the appropriate trials from the original data
using ft_selectdata.

Hope that helps,
Eelke
On Wed, 7 Nov 2018 at 13:28, Snijders, T.M. (Tineke)
<tineke.snijders at donders.ru.nl> wrote:
>
> Hi,
>
>
>
> I am using trials of different lengths, which seems to give a problem in ft_rejectvisual. It wasn’t a problem before (I think in 2016) when I did the same analysis.
>
>
>
> When using ft_rejectvisual, in the current fieldtrip version in the output data all trial lengths are reduced to the shortest trial-length, cutting away the remainder of the trial. In the command window it gives a warning of ‘inconsistent sampling info’.
>
>
>
> Is there a workaround to still get the full trial-lengths for the artifact rejected data? I do want to keep the complete trials at this point.
>
>
>
> Thanks,
>
>
>
> Tineke
>
>
>
> --
> Dr T.M. Snijders
> Research Staff
> Max Planck Institute for Psycholinguistics, Nijmegen
>
> www.ru.nl/people/donders/snijders-t
>
> http://www.mpi.nl/departments/language-development
>
> MPI | Wundtlaan 1 | Room 246 | tel 024 35 21246 | PO Box 310 | 6500 AH Nijmegen
>
>
>
>
> _______________________________________________
> fieldtrip mailing list
> https://mailman.science.ru.nl/mailman/listinfo/fieldtrip
> https://doi.org/10.1371/journal.pcbi.1002202




More information about the fieldtrip mailing list