- Local sensitivity analysis, this can be added to any simulation task by defining the inputs (e.g. parameters, compartmental volumes, initial conditions) and outputs (e.g. species). Note that you can't use parameters/species/compartments that are subject to a repeated assignment as the output to a local sensitivity analysis. If you want to calculate the sensitivities for such quantities, you can use differentiation rules to calculate the sensitivities. E.g. if your repeated assignment is C = A + B, then the sensitivitiy of C wrt input parameter X would be dC/dX = dA/dX+dB/dX. You would have to calculate this afterwards from the simData.
- Global sensitivity analysis. You can use Sobol GSA and Multiparametric GSA see the documentation: sbiosobol, sbiompgsa. These methods are currently not yet supported in the GUI but we have an app available to run these analyses, see here. In order to work with this, you can export your model (screenshot below) from SimBiology to the MATLAB Workspace (e.g. name the model object m1 in the workspace), selecting variants/doses from the model (e.g. dose = m1.Dose(1) and variants = m1.Variants([1 2]);), then run the GSA app by calling on the MATLAB command line: startGlobalSensitivityAnalysisApp(m1,dose,variants). If you don't have doses or variants, you can omit these input arguments from the startGlobalSensitivityAnalysisApp syntax. In the app (see screenshot below), you need to define the input parameters (parameters, species initial conditions, compartments), their ranges (e.g. CL between 0.1 and 10), number of iterations, output times and the observables (for Sobol) or classifier(s) (for MPGSA). I suggest you start with 3-5 parameters and a sample size of 1000-2000 to try things out and then scale up if need be. Note that the number of samples scales exponentially with the number of inputs.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/310613/image.jpeg)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/310616/image.jpeg)