[FieldTrip] ft_channelrepair with eeg data

Stephen Whitmarsh stephen.whitmarsh at gmail.com
Fri Jul 8 15:44:44 CEST 2011


He Tom,

Wow, look what was made this morning by Jorn at basecamp:

http://fieldtrip.fcdonders.nl/faq/how_can_i_define_neighbouring_sensors

Cheers,

Stephen (Pte(T))



On 8 July 2011 15:28, Marshall, T.R. (Tom) <t.marshall at fcdonders.ru.nl> wrote:
>
> Hi Fieldtrip-warriors,
>
> I'm trying to use function ft_channelrepair to remove and reinterpolate some bad channels in my eeg data. My syntax looks like this:-
>
> ###
>
>   channels_to_repair={'FT9', 'CPz'};
>
>   cfg=[];
>   cfg.neighbourdist = 4;
>   cfg.badchannel=channels_to_repair;
>
>   data=ft_channelrepair(cfg, data);
>
> ###
>
> Running this produces the following error msg:
>
> ###
>
>   ??? Error using ==> ft_checkconfig at 157
>   The field cfg.neighbours is required
>
>
>   Error in ==> ft_channelrepair at 58
>   cfg = ft_checkconfig(cfg, 'required', {'neighbours'});
>
> ###
>
> It seems that the underlying function ft_checkconfig requires a field 'cfg.neighbours' that ft_channelrepair does not. But... what value should be specified here?
>
> I also see the following in the help file for ft_channelrepair:-
>
> ###
>
>     Since a nearest neighbour average is used, the input should contain
>     a gradiometer or electrode definition, i.e. data.grad or data.elec.
>
> ###
>
> What exactly is this 'electrode definition'? A layout file for the electrodes? Are there prespecified templates or should I supply my own, and is there a function to correctly add this field to the data structure?
>
> I'm using a standard 10-10 64-electrode layout.
>
> Best,
>
> --
> Tom Marshall, MSc.
> Neuronal Oscillations Group, Donders Centre for Cognitive Neuroimaging
> tel: +31(0)243668487
> email: t.marshall at fcdonders.ru.nl
> postal: PO Box 9101, 6500HB, Nijmegen, The Netherlands
> visiting: Kapittelweg 29, 6525EN, Nijmegen, The Netherlands
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip




More information about the fieldtrip mailing list