Skip to content

sensitivity.sensitivity_fast

Global sensitivity analysis using FAST (Fourier Amplitude Sensitivity Test).

This module implements variance-based global sensitivity analysis using the Fourier Amplitude Sensitivity Test (FAST). FAST quantifies the contribution of individual model parameters to the variance of model outputs by mapping parameter variations onto periodic functions and analyzing the resulting output spectrum in the frequency domain.

The method provides efficient estimation of first-order (main-effect) sensitivity indices and, in extended variants (eFAST), total-effect indices. Compared to Monte Carlo–based Sobol methods, FAST offers favorable scaling with the number of parameters and is well suited for medium- to large-scale deterministic models.

This implementation is intended for use in computational modeling workflows, including systems biology, pharmacokinetics/pharmacodynamics, and digital twin applications, where a robust global assessment of parameter influence is required.

References

Cukier, R. I., Fortuin, C. M., Shuler, K. E., Petschek, A. G., & Schaibly, J. H. (1973). Study of the sensitivity of coupled reaction systems to uncertainties in rate coefficients. I. Theory. Journal of Chemical Physics, 59, 3873–3878. https://doi.org/10.1063/1.1680571

Saltelli, A., Tarantola, S., & Chan, K. P.-S. (1999). A quantitative model-independent method for global sensitivity analysis of model output. Technometrics, 41(1), 39–56. https://doi.org/10.1080/00401706.1999.10485594

FASTSensitivityAnalysis

FASTSensitivityAnalysis(
    sensitivity_simulation,
    parameters,
    groups,
    results_path,
    N,
    M=4,
    seed=None,
    n_cores=None,
    cache_results=False,
    **kwargs,
)

Bases: SensitivityAnalysis

Global sensitivity analysis using the Fourier Amplitude Sensitivity Test.

This class implements the FAST methodology for estimating first-order and total-effect sensitivity indices. It integrates with the common sensitivity analysis infrastructure provided by SensitivityAnalysis and supports grouped analyses and multiple model outputs.

References

Cukier et al. (1973); Saltelli et al. (1999)

Initialize a FAST sensitivity analysis.

Parameters:

Name Type Description Default
sensitivity_simulation SensitivitySimulation

Simulation object defining how model evaluations are performed.

required
parameters list[SensitivityParameter]

List of parameters included in the sensitivity analysis.

required
groups list[AnalysisGroup]

Analysis groups defining parameter perturbations or scenarios.

required
results_path Path

Directory where results and figures are stored.

required
N int

Base sample size controlling the total number of model evaluations. The total number of samples scales with N * num_parameters.

required
M int

Interference parameter defining the number of harmonics used in the Fourier series decomposition (default: 4).

4
seed int | None

Optional random seed for reproducibility.

None
n_cores int | None

Optional number of CPU cores used for parallel execution.

None
cache_results bool

Whether to cache sensitivity results to disk.

False
**kwargs

Additional keyword arguments passed to the base class.

{}

create_samples

create_samples()

Create parameter samples for FAST analysis.

This method generates FAST samples for each analysis group using the SALib FAST sampler. The resulting samples are stored as xarray objects and later used for model evaluation.

calculate_sensitivity

calculate_sensitivity(cache_filename=None, cache=False)

Compute FAST sensitivity indices for all model outputs.

This method performs the extended Fourier Amplitude Sensitivity Test (eFAST) to estimate first-order (S1) and total-effect (ST) sensitivity indices, along with corresponding confidence intervals, for each model output and parameter.

Parameters:

Name Type Description Default
cache_filename str | None

Optional filename for reading or writing cached sensitivity results.

None
cache bool

Whether to read from or write results to cache.

False
Notes

The sensitivity indices are computed independently for each output variable and stored in a structured xarray-based format.

plot

plot()

Generate standard FAST sensitivity plots.

This method creates heatmaps and bar plots for first-order (S1) and total-effect (ST) sensitivity indices for each analysis group and stores the resulting figures in the configured results directory.