canlab / MediationToolbox

Single-level and multi-level mediation analyses for any kind of data, with bootstrap-based significance testing. Neuroimaging-oriented functions allow for mediation effect parametric mapping (mapping of mediation effects across the brain) and multivariate mediation.
https://canlabweb.colorado.edu/wiki/doku.php/help/mediation/m3_mediation_fmri_toolbox
83 stars 29 forks source link

Error when using SPM12 #23

Open Shelling0 opened 3 years ago

Shelling0 commented 3 years ago

Hello Tor,

Is the toolbox not compatible with SPM12?

I was conducting a multilevel whole brain mediation analysis using this amazing toolbox together with SPM12. However, a fatal error occurred, which was related to the _image_eval_functionmultisubj function (line 143), and read "I don't recognize your version of SPM!". I tried to modify the function a bit but sadly failed. Then I switched to SPM8 and it seemed to work just fine.

If the problem really is the incompatibility with SPM12, do you have any plan to update the toolbox in the near future?

Thanks in advance,

Shelling.

torwager commented 3 years ago

Hi! It is compatible, and this error should have been fixed in a recent version. If you have the latest I expect it should work.

None of the relevant functionality of SPM is different between SPM8 and SPM12, so this is just a bookkeeping issue really. We’re just using SPM’s image reading/writing functions.

Best, Tor

On Oct 12, 2021, at 2:39 AM, Shelling @.***> wrote:

Hello Tor,

Is the toolbox not compatible with SPM12?

I was conducting a multilevel whole brain mediation analysis using this amazing toolbox together with SPM12. However, a fatal error occurred, which was related to the image_eval_function_multisubj function (line 143), and read "I don't recognize your version of SPM!". I tried to modify the function a bit but sadly failed. Then I switched to SPM8 and it seemed to work just fine.

If the problem really is the incompatibility with SPM12, do you have any plan to update the toolbox in the near future?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/canlab/MediationToolbox/issues/23, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABPY7LEFDFDNX4R2XCZ4XDLUGPJ2ZANCNFSM5FZY47FQ. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Shelling0 commented 3 years ago

Thanks, Tor. The problem is solved!

The error was caused by my using an old version of CanlabCore toolbox. With the latest CablanCore, no error occurs.