hMRI-group / hMRI-toolbox

A toolbox for quantitative MRI and in vivo histology using MRI (hMRI)
GNU General Public License v2.0
61 stars 44 forks source link

Fix error if optimization toolbox not present during NLLS R2* calculation #92

Closed Barisevrenugur closed 6 months ago

Barisevrenugur commented 9 months ago

This is a Hackathon-based PR:

In the hmri_calc_R2s, although the default method (OLS) does not make use of any specific toolboxes, the optional methods

{'nlls_ols','nlls_wls1','nlls_wls2','nlls_wls3'}

use the Optimization Toolbox in the call to lsqcurvefit. This causes confusion to user, creating a false test, when the tests are run and the user does not have the Optimization Toolbox.