[FieldTrip] possible bug when using old neuromas data with newer fieldtrip version

russ port russgport at gmail.com
Tue Jun 20 03:54:07 CEST 2017


Hi All,

Sorry to bother you all, but I was wondering if I may have found a possible bug. If so, I’ll submit a request to the bugzilla subsection. I am not completely sure the issue is not my own incompetence though. The error occurs when using a neuromag dataset that was read in with an old fieldtrip version (i.e. from 2015), and having it undergo ft_artifact_zvalue from a newer version of fieldtrip. 

In short, I use the following code:
 	
	load('MEGGRAD_Visual_clean_combinedscripts')
        
        datanoline=[]
        datanoline=data_clean

	load('/MEGGRADfinal_cleaned_jumpartifact_outputcfg_redone_Visual.mat') 
            

        cfgaj                    = [];

        % channel selection, cutoff and padding
        cfgaj.artfctdef.zvalue.channel    = allchanell;
        cfgaj.artfctdef.zvalue.cutoff     =   cfgajout.artfctdef.zvalue.cutoff
        cfgaj.artfctdef.zvalue.trlpadding = 0;
        cfgaj.artfctdef.zvalue.artpadding = 0;
        cfgaj.artfctdef.zvalue.fltpadding = 0.0;

        % algorithmic parameters
        cfgaj.artfctdef.zvalue.cumulative    = 'yes'; 
        cfgaj.artfctdef.zvalue.medianfilter  = 'yes';
        cfgaj.artfctdef.zvalue.medianfiltord = 9;
        cfgaj.artfctdef.zvalue.absdiff       = 'yes';
    	% cfgaj.artfctdef.zvalue.interactive = 'yes';

        [cfgajout, artifact_jump] = ft_artifact_zvalue(cfgaj,datanoline);

When I run this code in a 2015 version of fieldtrip, it works fine (without any error). On the other hand, in the 2016 version of fieldtrip I have (as well as in the latest version which  I downloaded this weekend), I get the following error:

Error using ft_datatype_sens (line 278)
unexpected number of coils (408)
contributing to channel MEG0113 (1)

Error in ft_datatype_raw (line 141)
      data.grad =
      ft_datatype_sens(data.grad);

Error in ft_checkdata (line 236)
  data = ft_datatype_raw(data,
  'hassampleinfo', hassampleinfo);

Error in ft_artifact_zvalue (line 215)
  data = ft_checkdata(data, 'datatype',
  'raw', 'hassampleinfo', 'yes’);


The dataset datanoline (as well as cfgaj) are linked to below (sorry it’s dropbox, but I’m not quite sure how to do it otherwise).

https://www.dropbox.com/s/86t5agwv2vanrh3/MEGGRAD_Visual_clean_combinedscripts.mat?dl=0 <https://www.dropbox.com/s/86t5agwv2vanrh3/MEGGRAD_Visual_clean_combinedscripts.mat?dl=0>

https://www.dropbox.com/s/rw8e7mof8plss72/MEGGRADfinal_cleaned_jumpartifact_outputcfg_redone_Visual.mat?dl=0 <https://www.dropbox.com/s/rw8e7mof8plss72/MEGGRADfinal_cleaned_jumpartifact_outputcfg_redone_Visual.mat?dl=0>

Sorry for the bother,
Russ



   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20170619/73e4bf13/attachment-0001.html>


More information about the fieldtrip mailing list