Authored by Francois Tadel

Moved files

function D=ImaGIN_InterpolationFilter(S)
% Correct artefacts in frequency space
%
% REFERENCES:
% - Ramirez & Baillet, 2011
% -=============================================================================
% This function is part of the ImaGIN software:
% https://f-tract.eu/
%
% This software is distributed under the terms of the GNU General Public License
% as published by the Free Software Foundation. Further details on the GPLv3
% license can be found at http://www.gnu.org/copyleft/gpl.html.
%
% FOR RESEARCH PURPOSES ONLY. THE SOFTWARE IS PROVIDED "AS IS," AND THE AUTHORS
% DO NOT ASSUME ANY LIABILITY OR RESPONSIBILITY FOR ITS USE IN ANY CONTEXT.
%
% Copyright (c) 2000-2018 Inserm U1216
% =============================================================================-
%
% Authors: Olivier David
% Correct artefacts in frequency space
% Ref: Ramirez & Baillet, 2011
try
t=S.Fname;
... ... @@ -135,7 +118,7 @@ for i0=1:size(t,1)
for i1=1:length(CompoArtefact)
U2(:,i1)=2*U(:,i1)-filter(ones(1,windowSize)/windowSize,1,U(:,i1))-flipud(filter(ones(1,windowSize)/windowSize,1,flipud(U(:,i1))));
end
Artefact=ImaGIN_normalisation(sum(abs(U2),2),1);
Artefact=ImaGIN_Normalisation(sum(abs(U2),2),1);
windowSize = round(1*length(Artefact)/length(ev));
Artefact=2*Artefact-filter(ones(1,windowSize)/windowSize,1,Artefact)-flipud(filter(ones(1,windowSize)/windowSize,1,flipud(Artefact)));
... ...