Sensitivity analysis
Sensitivity analysis is the study of how the uncertainty in the output of a mathematical model or system can be divided and allocated to different sources of uncertainty in its inputs. A related practice is uncertainty analysis, which has a greater focus on uncertainty quantification and propagation of uncertainty; ideally, uncertainty and sensitivity analysis should be run in tandem.
The process of recalculating outcomes under alternative assumptions to determine the impact of a variable under sensitivity analysis can be useful for a range of purposes, including:
- Testing the robustness of the results of a model or system in the presence of uncertainty.
- Increased understanding of the relationships between input and output variables in a system or model.
- Uncertainty reduction, through the identification of model inputs that cause significant uncertainty in the output and should therefore be the focus of attention in order to increase robustness.
- Searching for errors in the model.
- Model simplification – fixing model inputs that have no effect on the output, or identifying and removing redundant parts of the model structure.
- Enhancing communication from modelers to decision makers.
- Finding regions in the space of input factors for which the model output is either maximum or minimum or meets some optimum criterion.
- In case of calibrating models with large number of parameters, a primary sensitivity test can ease the calibration stage by focusing on the sensitive parameters. Not knowing the sensitivity of parameters can result in time being uselessly spent on non-sensitive ones.
- To seek to identify important connections between observations, model inputs, and predictions or forecasts, leading to the development of better models.
Overview
Quite often, some or all of the model inputs are subject to sources of uncertainty, including errors of measurement, absence of information and poor or partial understanding of the driving forces and mechanisms. This uncertainty imposes a limit on our confidence in the response or output of the model. Further, models may have to cope with the natural intrinsic variability of the system, such as the occurrence of stochastic events.
Good modeling practice requires that the modeler provide an evaluation of the confidence in the model. This requires, first, a quantification of the uncertainty in any model results ; and second, an evaluation of how much each input is contributing to the output uncertainty. Sensitivity analysis addresses the second of these issues, performing the role of ordering by importance the strength and relevance of the inputs in determining the variation in the output.
In models involving many input variables, sensitivity analysis is an essential ingredient of model building and quality assurance. National and international agencies involved in impact assessment studies have included sections devoted to sensitivity analysis in their guidelines. Examples are the European Commission, the White House Office of Management and Budget, the Intergovernmental Panel on Climate Change and US Environmental Protection Agency's modeling guidelines. In a comment published in 2020 in the journal Nature 22 scholars take COVID-19 as the occasion for suggesting five ways to make models serve society better. One of the five recommendations, under the heading of 'Mind the assumptions' is to 'perform global uncertainty and sensitivity analyses allowing all that is uncertain — variables, mathematical relationships and boundary conditions — to vary simultaneously as runs of the model produce its range of predictions.'
Settings, constraints, and related issues
Settings and constraints
The choice of method of sensitivity analysis is typically dictated by a number of problem constraints or settings. Some of the most common are- Computational expense: Sensitivity analysis is almost always performed by running the model a number of times, i.e. a sampling-based approach. This can be a significant problem when,
- * A single run of the model takes a significant amount of time. This is not unusual with very complex models.
- * The model has a large number of uncertain inputs. Sensitivity analysis is essentially the exploration of the multidimensional input space, which grows exponentially in size with the number of inputs. See the curse of dimensionality.
- Correlated inputs: Most common sensitivity analysis methods assume independence between model inputs, but sometimes inputs can be strongly correlated. This is still an immature field of research and definitive methods have yet to be established.
- Nonlinearity: Some sensitivity analysis approaches, such as those based on linear regression, can inaccurately measure sensitivity when the model response is nonlinear with respect to its inputs. In such cases, variance-based measures are more appropriate.
- Model interactions: Interactions occur when the perturbation of two or more inputs simultaneously causes variation in the output greater than that of varying each of the inputs alone. Such interactions are present in any model that is non-additive, but will be neglected by methods such as scatterplots and one-at-a-time perturbations. The effect of interactions can be measured by the total-order sensitivity index.
- Multiple outputs: Virtually all sensitivity analysis methods consider a single univariate model output, yet many models output a large number of possibly spatially or time-dependent data. Note that this does not preclude the possibility of performing different sensitivity analyses for each output of interest. However, for models in which the outputs are correlated, the sensitivity measures can be hard to interpret.
- Given data: While in many cases the practitioner has access to the model, in some instances a sensitivity analysis must be performed with "given data", i.e. where the sample points cannot be chosen by the analyst. This may occur when a sensitivity analysis has to be performed retrospectively, perhaps using data from an optimisation or uncertainty analysis, or when data comes from a discrete source.
Assumptions vs. inferences
I have proposed a form of organized sensitivity analysis that I call 'global sensitivity analysis' in which a neighborhood of alternative assumptions is selected and the corresponding interval of inferences is identified. Conclusions are judged to be sturdy only if the neighborhood of assumptions is wide enough to be credible and the corresponding interval of inferences is narrow enough to be useful.
Note Leamer's emphasis is on the need for 'credibility' in the selection of assumptions. The easiest way to invalidate a model is to demonstrate that it is fragile with respect to the uncertainty in the assumptions or to show that its assumptions have not been taken 'wide enough'. The same concept is expressed by Jerome R. Ravetz, for whom bad modeling is when uncertainties in inputs must be suppressed lest outputs become indeterminate.
Pitfalls and difficulties
Some common difficulties in sensitivity analysis include- Too many model inputs to analyse. Screening can be used to reduce dimensionality. Another way to tackle the curse of dimensionality is to use sampling based on low discrepancy sequences
- The model takes too long to run. Emulators can reduce the number of model runs needed.
- There is not enough information to build probability distributions for the inputs. Probability distributions can be constructed from expert elicitation, although even then it may be hard to build distributions with great confidence. The subjectivity of the probability distributions or ranges will strongly affect the sensitivity analysis.
- Unclear purpose of the analysis. Different statistical tests and measures are applied to the problem and different factors rankings are obtained. The test should instead be tailored to the purpose of the analysis, e.g. one uses Monte Carlo filtering if one is interested in which factors are most responsible for generating high/low values of the output.
- Too many model outputs are considered. This may be acceptable for the quality assurance of sub-models but should be avoided when presenting the results of the overall analysis.
- Piecewise sensitivity. This is when one performs sensitivity analysis on one sub-model at a time. This approach is non conservative as it might overlook interactions among factors in different sub-models.
- Commonly used OAT approach is not valid for nonlinear models. Global methods should be used instead.
Sensitivity analysis methods
- Quantify the uncertainty in each input. Note that this can be difficult and many methods exist to elicit uncertainty distributions from subjective data.
- Identify the model output to be analysed.
- Run the model a number of times using some design of experiments, dictated by the method of choice and the input uncertainty.
- Using the resulting model outputs, calculate the sensitivity measures of interest.
The various types of "core methods" are distinguished by the various sensitivity measures which are calculated. These categories can somehow overlap. Alternative ways of obtaining these measures, under the constraints of the problem, can be given.
One-at-a-time (OAT)
One of the simplest and most common approaches is that of changing one-factor-at-a-time, to see what effect this produces on the output. OAT customarily involves- Moving one input variable, keeping others at their baseline values, then,
- Returning the variable to its nominal value, then repeating for each of the other inputs in the same way.
OAT is frequently preferred by modellers because of practical reasons. In case of model failure under OAT analysis the modeller immediately knows which is the input factor responsible for the failure.
Despite its simplicity however, this approach does not fully explore the input space, since it does not take into account the simultaneous variation of input variables. This means that the OAT approach cannot detect the presence of interactions between input variables.
Derivative-based local methods
Local derivative-based methods involve taking the partial derivative of the output Y with respect to an input factor Xi:where the subscript X0 indicates that the derivative is taken at some fixed point in the space of the input. Adjoint modelling and Automated Differentiation are methods in this class. Similar to OAT, local methods do not attempt to fully explore the input space, since they examine small perturbations, typically one variable at a time.
Regression analysis
, in the context of sensitivity analysis, involves fitting a linear regression to the model response and using standardized regression coefficients as direct measures of sensitivity. The regression is required to be linear with respect to the data because otherwise it is difficult to interpret the standardised coefficients. This method is therefore most suitable when the model response is in fact linear; linearity can be confirmed, for instance, if the coefficient of determination is large. The advantages of regression analysis are that it is simple and has a low computational cost.Variance-based methods
Variance-based methods are a class of probabilistic approaches which quantify the input and output uncertainties as probability distributions, and decompose the output variance into parts attributable to input variables and combinations of variables. The sensitivity of the output to an input variable is therefore measured by the amount of variance in the output caused by that input. These can be expressed as conditional expectations, i.e., considering a model Y = f for X =, a measure of sensitivity of the ith variable Xi is given as,where "Var" and "E" denote the variance and expected value operators respectively, and X~i denotes the set of all input variables except Xi. This expression essentially measures the contribution Xi alone to the uncertainty in Y, and is known as the first-order sensitivity index or main effect index. Importantly, it does not measure the uncertainty caused by interactions with other variables. A further measure, known as the total effect index, gives the total variance in Y caused by Xi and its interactions with any of the other input variables. Both quantities are typically standardised by dividing by Var.
Variance-based methods allow full exploration of the input space, accounting for interactions, and nonlinear responses. For these reasons they are widely used when it is feasible to calculate them. Typically this calculation involves the use of Monte Carlo methods, but since this can involve many thousands of model runs, other methods can be used to reduce computational expense when necessary. Note that full variance decompositions are only meaningful when the input factors are independent from one another.
Variogram analysis of response surfaces (''VARS'')
One of the major shortcomings of the previous sensitivity analysis methods is that none of them considers the spatially ordered structure of the response surface/output of the model Y=f in the parameter space. By utilizing the concepts of directional variograms and covariograms, variogram analysis of response surfaces addresses this weakness through recognizing a spatially continuous correlation structure to the values of Y, and hence also to the values of.Basically, the higher the variability the more heterogeneous is the response surface along a particular direction/parameter, at a specific perturbation scale. Accordingly, in the VARS framework, the values of directional variograms for a given perturbation scale can be considered as a comprehensive illustration of sensitivity information, through linking variogram analysis to both direction and perturbation scale concepts. As a result, the VARS framework accounts for the fact that sensitivity is a scale-dependent concept, and thus overcomes the scale issue of traditional sensitivity analysis methods. More importantly, VARS is able to provide relatively stable and statistically robust estimates of parameter sensitivity with much lower computational cost than other strategies. Noteworthy, it has been shown that there is a theoretical link between the VARS framework and the variance-based and derivative-based approaches.
Screening
Screening is a particular instance of a sampling-based method. The objective here is rather to identify which input variables are contributing significantly to the output uncertainty in high-dimensionality models, rather than exactly quantifying sensitivity. Screening tends to have a relatively low computational cost when compared to other approaches, and can be used in a preliminary analysis to weed out uninfluential variables before applying a more informative analysis to the remaining set. One of the most commonly used screening method is the elementary effect method.Scatter plots
A simple but useful tool is to plot scatter plots of the output variable against individual input variables, after sampling the model over its input distributions. The advantage of this approach is that it can also deal with "given data", i.e., a set of arbitrarily-placed data points, and gives a direct visual indication of sensitivity. Quantitative measures can also be drawn, for example by measuring the correlation between Y and Xi, or even by estimating variance-based measures by nonlinear regression.Alternative methods
A number of methods have been developed to overcome some of the constraints discussed above, which would otherwise make the estimation of sensitivity measures infeasible. Generally, these methods focus on efficiently calculating variance-based measures of sensitivity.Emulators
Emulators are data-modeling/machine learning approaches that involve building a relatively simple mathematical function, known as an emulator, that approximates the input/output behavior of the model itself. In other words, it is the concept of "modeling a model". The idea is that, although computer models may be a very complex series of equations that can take a long time to solve, they can always be regarded as a function of their inputs Y = f. By running the model at a number of points in the input space, it may be possible to fit a much simpler emulator η, such that η ≈ f to within an acceptable margin of error. Then, sensitivity measures can be calculated from the emulator, which will have a negligible additional computational cost. Importantly, the number of model runs required to fit the emulator can be orders of magnitude less than the number of runs required to directly estimate the sensitivity measures from the model.Clearly, the crux of an emulator approach is to find an η that is a sufficiently close approximation to the model f. This requires the following steps,
- Sampling the model at a number of points in its input space. This requires a sample design.
- Selecting a type of emulator to use.
- "Training" the emulator using the sample data from the model – this generally involves adjusting the emulator parameters until the emulator mimics the true model as well as possible.
- Gaussian processes, where any combination of output points is assumed to be distributed as a multivariate Gaussian distribution. Recently, "treed" Gaussian processes have been used to deal with heteroscedastic and discontinuous responses.
- Random forests, in which a large number of decision trees are trained, and the result averaged.
- Gradient boosting, where a succession of simple regressions are used to weight data points to sequentially reduce error.
- Polynomial chaos expansions, which use orthogonal polynomials to approximate the response surface.
- Smoothing splines, normally used in conjunction with HDMR truncations.
High-dimensional model representations (HDMR)
A high-dimensional model representation is essentially an emulator approach, which involves decomposing the function output into a linear combination of input terms and interactions of increasing dimensionality. The HDMR approach exploits the fact that the model can usually be well-approximated by neglecting higher-order interactions. The terms in the truncated series can then each be approximated by e.g. polynomials or splines and the response expressed as the sum of the main effects and interactions up to the truncation order. From this perspective, HDMRs can be seen as emulators which neglect high-order interactions; the advantage is that they are able to emulate models with higher dimensionality than full-order emulators.Fourier amplitude sensitivity test (FAST)
The Fourier amplitude sensitivity test uses the Fourier series to represent a multivariate function in the frequency domain, using a single frequency variable. Therefore, the integrals required to calculate sensitivity indices become univariate, resulting in computational savings.Other
Methods based on Monte Carlo filtering. These are also sampling-based and the objective here is to identify regions in the space of the input factors corresponding to particular values of the output.Applications
Examples of sensitivity analyses can be found in various area of application, such as:- Environmental sciences
- Business
- Social sciences
- Chemistry
- Engineering
- Epidemiology
- Meta-analysis
- Multi-criteria decision making
- Time-critical decision making
- Model calibration
Sensitivity auditing
In order to take these concerns into due consideration the instruments of SA have been extended to provide an assessment of the entire knowledge and model generating process. This approach has been called 'sensitivity auditing'. It takes inspiration from NUSAP, a method used to qualify the worth of quantitative information with the generation of `Pedigrees' of numbers. Likewise, sensitivity auditing has been developed to provide pedigrees of models and model-based inferences. Sensitivity auditing has been especially designed for an adversarial context, where not only the nature of the evidence, but also the degree of certainty and uncertainty associated to the evidence, will be the subject of partisan interests. Sensitivity auditing is recommended in the European Commission guidelines for impact assessment, as well as in the report Science Advice for Policy by European Academies.
Related concepts
Sensitivity analysis is closely related with uncertainty analysis; while the latter studies the overall uncertainty in the conclusions of the study, sensitivity analysis tries to identify what source of uncertainty weighs more on the study's conclusions.The problem setting in sensitivity analysis also has strong similarities with the field of design of experiments. In a design of experiments, one studies the effect of some process or intervention on some objects. In sensitivity analysis one looks at the effect of varying the inputs of a mathematical model on the output of the model itself. In both disciplines one strives to obtain information from the system with a minimum of physical or numerical experiments.