Hi
With the kind of dimensions you’re talking about this does not work - easy to see given that the ‘non-aggressive’ denoising does not result in a full loss of degrees of freedom per column in the noise time series matrix but fsl_glm or any other OLS GLM will. This is due to the possible temporal non-orthogonality between the noise and non-noise time series.
You can form a matrix that is of full time series rank (i.e. is a txt matrix) that does this (i.e. give you the nonagrresively denoised data when used as a GLM design matrix in fsl_glm:
If X=(X_1|X_2) is the melodic mixing matrix where we want to remove effects in X_2 only then the denoised data is given by
Y_clean = ( Id - X_2 * (0 | Id_2) pinv(X)) * Y
Where Y is the original data and Id is the Identity matrix (t x t) and Id_2 is the identity matrix of size n2, where n2 is the number of nice components.
You would need to feed the pseudo-inverse of that leading matrix into fsl_glm to denoise the data, you can use the Woodbury matrix identity to work out how to write that in a more compact form.
hth
Christian
> On 22. Jun 2017, at 02:24, SUBSCRIBE FSL James Kent <[log in to unmask]> wrote:
>
> Hi FSL experts (perhaps specifically Dr. Christian F. Beckmann),
>
> I'm working on adding ICA_AROMA functionality to another software tool (fmriprep): https://github.com/poldracklab/fmriprep/pull/539
>
> where I'm having trouble:
> I'm attempting to recreate the fsl_regfilt partial regression equation, but instead of the output being the denoised data, I want a matrix of confounds where each column is a noise component, and the rows are the length of the time series.
>
> I see fsl_regfilt's partial regression explained here: https://www.jiscmail.ac.uk/cgi-bin/webadmin?A2=ind1307&L=fsl&D=0&P=288785
>
> My thought process right now is to:
>
> 1) regress the image data against the entire melodic_mix:
> data_hat = B0 + B1*melodic_mix
> residual_data = data - data_hat
>
> 2) regress the noise_components against the signal_components and the residual_data
> noise_components_hat = B0 + B1*signal_components + B2*residual_data
> residual_noise_components = noise_components - noise_components_hat
>
> The residual_noise_components are the partially regressed noise components and if given to fsl_glm as a design matrix would give the same result as using fsl_regfilt with the filter and melodic_mix.
>
> Is my reasoning sound? Can anyone help with how I can conceptualize making this regression?
>
> Thank you so much!
> James
|