using -Rerrts output from 3dremlfit for resting state

Hello afni experts,

I have a question regarding the use of -Rerrts output from 3dremlfit for resting state data. I should first mention that I am analyzing resting state data but instead of looking at functional connectivity I want to investigate if BOLD signal variability (calculated with the MSSD measure) increases after an intervention. So the actual amount of variability in the remaining residuals is very important for my analysis.
I read on this message board that it is not recommended to use prewhitening in resting state because the autocorrelation in the remaining residuals is assumed to be related to neural activity so we don t want to whiten the residuals. My question is: What is your opinion about using the unwhitened residuals (the output of the -Rerrts option) from 3dremlfit instead of the residuals from 3dDeconvolve?

The reason why I am asking is because of a paper by Molly Bright that caught my attention: “Potential pitfalls when denoising resting state fMRI data using nuisance regression”. She argues that also in resting state the fitting procedure should include an estimate of the autocorrelation in the residuals and account for this during the fit to achieve valid statistical inference.

So I would like to use the remaining unwhitened residuals from 3dremlfit instead of the residuals from 3dDeconvolve assuming they will be more accurate? When I look at some of my data, the remaining residuals from 3dDeconvolve and the output from remlfit -Rerrts do seem to differ. I am just wondering what you guys think and if this is something that could potentially make a difference for my type of analysis (BOLD signal variability -MSSD).

Thank you very much in advance for any thoughts!

There are two distinct aspects to prewhitening that need to be distinguished here.
[li] Prewhitening the model equations to convert the correlated “noise” (part of signal excluded from the model) into white (uncorrelated) noise, so that least squares estimation of the regression parameters is efficient and statistics about those parameters are accurate.
[/li][li] Prewhitening the residuals, which are the data minus the fitted model, so that they are uncorrelated in time.
Mathematically, these operations are closely related, but for the practical purposes of FMRI analyses they are distinct.

The first one is for the purpose of producing the most accurate possible estimate of the regression parameters, the deterministic part of the model. In the context of rs-FMRI data, this deterministic model is itself of little interest, but is rather to be subtracted from the data to get the residuals – which are the “signal” of interest now – to be correlated across space, rather than time.

For the most part, people have generally done inter-regional correlations using the direct residuals, without prewhitening them – that is, they use “-Rerrts” instead of “-Rwherr” in 3dREMLfit. There is no super-strong principle behind this, but it makes sense for a couple reasons:
[li] Prewhitening a time series involves mixing values up across time points. In the case of 3dREMLfit, where the prewhitening amount varies among voxels, the amount of temporal mixing will vary between pairs of prewhitened voxel time series being correlated. It is difficult to wrap one’s mind around the statistical and/or causal implications of this effect. [size=small][NOTE: this effect would be absent if the same amount of prewhitening was applied to all voxels, as in some other software packages whose names will not pass my lips.][/size]
[/li][li] Temporal autocorrelation in the voxel time series basically downweights the higher frequencies of oscillation in the data, and prewhitening will boost those higher frequencies up in magnitude. Do you want to do that? Not so clear to me.

For the above reasons, it makes sense to me to use 3dREMLfit -Rerrts to “regress out” the deterministic model (baseline, baseline drift, motion effects, …) and use the “plain” residuals for further rs-FMRI analyses. However, if one were to use 3dDeconvolve -errts instead, I doubt that the differences would be significant in the big picture of trying to understand the brain.

Thank you very much for this explanation! That makes sense to me!

Sorry, I actually have a follow up question!
When I run my script I get a fatal error: Can’t open dataset errts.P1002_REML+org

here is my script : -subj_id ${subj}
-script proc.py_scripts3/proc_${subj}.sh
-out_dir ${top_dir}${subj}/${subj}.3dDeconvolve_reml
-dsets ${func_dir}pb04.P1002.scale_masked_Despiked_wds.nii.gz
-blocks regress -regress_reml_exec -regress_opts_reml -Rerrts denoised -regress_motion_file /tmp/yassamri2/Tsukuba/hierarchical/BOLD_variability/data/P1/G1/P1002/P1002.preprocessedtest/dfile_rall.1D -regress_apply_mot_types demean deriv -regress_extra_ortvec ${stim_times_dir}cwm.1D ${stim_times_dir}ccsf.1D -regress_extra_ortvec_labels cwm ccsf

Looks like the dataset errts.P1002_REML+org is not created because I use the option -Rerrts denoised? What is the default errts output when using real? Is errts.P1002_REML+org by default Rerrts?