Back to the main page.

Bug 1326 - preproc loop can be removed in rejectvisual_XXX and ft_timelockanalysis when cfg.preproc is empty

Status CLOSED FIXED
Reported 2012-02-13 12:13:00 +0100
Modified 2012-03-14 10:00:40 +0100
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P3 normal
Assigned to: Eelke Spaak
URL:
Tags:
Depends on:
Blocks:
See also:

Jörn M. Horschig - 2012-02-13 12:13:00 +0100

Email conversation: -------------- Hey JM, I just found these lines in rejectvisual_trial: for i=1:ntrl ft_progress(i/ntrl, 'filtering data in trial %d of %d\n', i, ntrl); [data.trial{i}, label, time, cfg.preproc] = preproc(data.trial{i}, data.label, fsample, cfg.preproc, offset(i)); end I had the impression that a filter was used by default. I do not use want to use any filter, thus no cfg.preproc, and luckily the default is also that it is empty. Is it okay if we make the loop conditional on whether cfg.preproc is not empty, or does preproc do anything else with the data? I couldn't find any apparent difference prior and after the loop. Note that from the output arguments, label and time are not used. And cfg.preproc should contain only default settings (which should all be disabled filtersettings), right? On the one hand it would speed things greatly up, on the other hand it would remove the ambiguous (and wrong) text output. Am I missing something here? Best, Jörn -------------- I think not. If the default cfg does not affect the output data, I would say you could make it conditional. Note: is there no basseline-correction involved? JM PS: note that this also could to be done in ft_timelockanalysis -------------- I don't think so: polyremoval: 'no' polyorder: 2 detrend: 'no' demean: 'no' baselinewindow: 'all' Best, Jörn


Eelke Spaak - 2012-02-29 14:38:04 +0100

Fixed in rejectvisual_trial and rejectvisual_channel; not applicable for rejectvisual_summary (preproc called anyway for selection of data); ft_timelockanalysis already checked for an empty cfg.preproc.


Eelke Spaak - 2012-02-29 14:54:52 +0100

Sorry, forgot: revision 5333.


Eelke Spaak - 2012-03-14 10:00:40 +0100

closing several bugs that have been RESOLVED for a long time