MBB-team / VBA-toolbox

The VBA toolbox
GNU General Public License v3.0
129 stars 67 forks source link

Prefix spm functions #43

Closed lionel-rigoux closed 7 years ago

lionel-rigoux commented 7 years ago

The toolbox includes of lot of spm functions that can conflict with any other som installation. This set of changes index all spm funcitons within the toolbox with "VBA_" to avoid any problems.

jdaunize commented 7 years ago

Hey, I can see a lot of SPM functions that have no utility (if I'm correct) in VBA, in particular: VBA_spm_Ce.m VBA_spm_Q.m VBA_spm_XYZreg.m VBA_spm_dcm_batch.m VBA_spm_dcm_fmri_check.m VBA_spm_dcm_test.m VBA_spm_deconv.m VBA_spm_defaults.m) VBA_spm_detrend.m VBA_spm_diff.m VBA_spm_existfile.m VBA_spm_fieldindices.m VBA_spm_figure.m VBA_spm_file.m VBA_spm_fileparts.m VBA_spm_get_defaults.m VBA_spm_input.m VBA_spm_inv.m VBA_spm_length.m VBA_spm_matrix.m VBA_spm_perm_mtx.m VBA_spm_platform.m VBA_spm_plot_ci.m VBA_spm_print.m VBA_spm_read_vols.m VBA_spm_resample.m VBA_spm_sample_vol.m VBA_spm_unlink.m VBA_spm_unvec.m VBA_spm_vec.m VBA_spm_vol.m VBA_spm_vol_nifti.m Can you identify why these functions are needed in VBA? J.

lionel-rigoux commented 7 years ago

I know... But those functions are called by other (higher level) functions, that are called by other functions... I did a dependency tree search to try and include all spm dependencies as VBA_ functions. That is, all functions here could be potentially called from the core toolbox/demo. The goal was to avoid conflicts with spm (which happened on my computer, creating quite nasty bugs) without too much thinking about the necessity. Having said that, it is true that a lot of spm calls could (should?) are quite superfluous and can be easily avoided. Once this branch has been merged, I suggest we start a round of spm hunting to reduce to the strict minimum the need for spm sub-routines.

lionel-rigoux commented 7 years ago

All the demos are running. Can I merge this?

jdaunize commented 7 years ago

OK !