Closed GallVp closed 1 year ago
Good job on the toolbox, btw. Thank you for your efforts.
fs = 512; on line 72 in ecg_removal masks fs = 1024; on line 56. DOn't you think that this making can result in wrong processing of sigIn{1, jj} and sigIn{2, jj} in the remaining steps.
I think the fs = 512 should be declared at the top as:
fs = 1024; fs_pressue = 512;
Hi Usman,
thank you so much for the detailed reports, and sorry for my ridiculously slow response time!
Both issues were very well spotted and should be fixed in the newest version. :-)
(I modified filter_signals
to now allow the user to specify where the extra channels are to be found. That should provide sufficient flexibility for all use cases, I hope. The sampling rate issue was a bug I apparently introduced a few months ago while working on another bug fix related to different sampling rates.)
The help section says (sigIn{ii, chan}(:, 4)):
% passTime: (Optional) If this is 1, the signal sigIn{ii, chan}(:, 4) is passed as an additional % input vector to the filter function, generally assuming that this contains the measurement time % in ms. If 0 (default), no additional vector is passed.
Where as the code uses (sigIn{ii, 4}):
[sigsOutLoc{:}] = algo(sigIn{ii, chan}(:, 1), sigIn{ii, 4});
I think the time vector should not be placed at sigIn{ii, 4} because it either limits the number of signal channels to 3 or creates the problem of non-contiguous signal channels in sigIn cell array. Rather, it should be placed at sigIn{ii, chan}(:, 2) or sigIn{ii, chan}(:, 3) depending on whether auxChannel and passTime are true or false.
Cheers Usman R.