Hi afni experts,
I do physiology noise correction to my EPI data recently. Physiology data of each epi run was picked out from the .resp and .puls files. If the EPI run with TR of 2 seconds has 120 TR and the physiology data has the sample rate of 50, 212050 time points from the start MDH Time of this run will be picked out. Then the 212050 points were saved as text files and then inputted to RetroTS.m to generate regressors.
But I found the t value between two experimental conditions became smaller after removing physiology noise. So I would like to know what RetroTS.m have done to generate the regressors and I open the function RetroTS.m. Then I found a problem at my first glance:
if (isfield(Opt,'SliceOrder'))
Opt.SliceOffset=zeros(Opt.Nslices,1);
if(strcmpi(Opt.SliceOrder,'alt+z'))
for (i=1:2:Opt.Nslices),
Opt.SliceOffset(i) = tt; tt = tt+dtt;
end
for (i=2:2:Opt.Nslices),
Opt.SliceOffset(i) = tt; tt = tt+dtt;
end
[size=x-large]...[/size]
elseif(strcmpi(Opt.SliceOrder,'alt-z'))
for (i=Opt.Nslices:-2:1),
Opt.SliceOffset(i) = tt; tt = tt+dtt;
end
for (i=Opt.Nslices-1:-2:1),
Opt.SliceOffset(i) = tt; tt = tt+dtt;
end
elseif(strcmpi(Opt.SliceOrder,'Custom'))
% timing already set in Opt.SliceOffset, do nothing
else
[size=x-large]...[/size]
If the options of the RetroTS are set like this:
Opt.SliceOffset = SliceOffset;
Opt.SliceOrder = 'Custom';
Opt.SliceOffset will become all zeros no matter what offset value you input.I am not sure it is a bug or deliberate setting.If it is a bug, there may be more bugs in this function because it was truly found at my first glance.
Do you think there is something wrong with my processing procedures or with the function RetroTS.m mentioned above?
Thank you in advance!