Back to the main page.
Bug 644 - ft_channelrepair does not work on missing channels
Status | CLOSED FIXED |
Reported | 2011-05-06 15:50:00 +0200 |
Modified | 2012-08-23 14:02:08 +0200 |
Product: | FieldTrip |
Component: | core |
Version: | unspecified |
Hardware: | All |
Operating System: | All |
Importance: | P1 enhancement |
Assigned to: | Jörn M. Horschig |
URL: | |
Tags: | |
Depends on: | |
Blocks: | |
See also: |
Jörn M. Horschig - 2011-05-06 15:50:34 +0200
personally, I need this since I got a dataset of patients with bandages around their head, which prevents us from putting electrodes at some positions whether this is an advisable thing to do or not can be argued about
Jörn M. Horschig - 2012-02-01 16:32:10 +0100
189 $ svn ci ft_channelrepair.m -m "bugfix-#644- channelrepair can repair missing channels now - note however that this is not recommended (yet), see bug#634" Sending ft_channelrepair.m Transmitting file data . Committed revision 5216. Related, see bug 634 - using spherical spline interpolation, reconstructing missing channels makes more sense
Boris Reuderink - 2012-02-03 21:24:55 +0100
Hi Jorn, do you perhaps have a test script for your changes? Or otherwise, are you confident that is works? I don't have a clue.
Jörn M. Horschig - 2012-02-06 13:42:14 +0100
Hey Boris, I could provide a test script. On the other hand, I already got mail from two people for which this did not work as they expected (which is more related to the fact that they were hacking this functionality into the code anyway, already). I'm gonna bring this up on Wednesday
Boris Reuderink - 2012-02-06 15:39:04 +0100
A test script would be great. Since it appears not completely fixed, I'll reopen this bug.
Boris Reuderink - 2012-02-06 15:39:24 +0100
Sorry, closed by habit. Reopening again.
Jörn M. Horschig - 2012-02-13 15:15:26 +0100
I extended the testscript for ft_channelrepair by testing for missing channel and borrowing data from bug 941. Sanity checks: for tr=1:numel(data_eeg_interp.trial) tmp = repmat(data_eeg_interp.trial{tr}(end, :), 4, 1); if all(tmp < data_eeg_interp.trial{tr}(cfg.neighbours, :)) | ... all(tmp > data_eeg_interp.trial{tr}(cfg.neighbours, :)) error(['The average is not in between its channel neighbours at for trial ' num2str(tr)]); elseif ~all(data_eeg_interp.trial{tr}(end, :) == data_eeg_repaired.trial{tr}(25, :)) error('The reconstruction of the same channel differs when being treated as a missing channel compared to a bad channel'); else fprintf('trial %i is fine\n', tr); end end 204 $ svn ci test_ft_channelrepair.m -m "enhancement-#644- extended test script for ft_channelrepair to include a case for missing channels" Sending test_ft_channelrepair.m Transmitting file data . Committed revision 5280.