sobol_dummy {sensobol}R Documentation

Computation of Sobol' indices for a dummy parameter

Description

This function computes first and total-order Sobol' indices for a dummy parameter following the formulas shown in Khorashadi Zadeh et al. (2017).

Usage

sobol_dummy(Y, params, R, n, parallel = "no", ncpus = 1)

Arguments

Y

Numeric vector, model output.

params

Vector with the name of the model inputs.

R

Integer, number of bootstrap replicas.

n

Integer, sample size of the sample matrix.

parallel

The type of parallel operation to be used (if any). If missing, the default is taken from the option "boot.parallel" (and if that is not set, "no"). For more information, check the parallel option in the boot function of the boot package.

ncpus

Integer: number of processes to be used in parallel operation: typically one would chose this to the number of available CPUs. Check the ncpus option in the boot function of the boot package.

Value

A data.table object. It includes a column with the results of the bootstrap.

References

Khorashadi Zadeh F, Nossent J, Sarrazin F, Pianosi F, van Griensven A, Wagener T, Bauwens W (2017). “Comparison of variance-based and moment-independent global sensitivity analysis approaches by application to the SWAT model.” Environmental Modelling and Software, 91, 210–222. ISSN 13648152, doi: 10.1016/j.envsoft.2017.02.001, http://dx.doi.org/10.1016/j.envsoft.2017.02.001.

See Also

Check the function boot for further details on the bootstrapping and the components available within the class boot.

Examples

# Define settings:
n <- 100; k <- 8; R <- 10
# Design the sample matrix:
A <- sobol_matrices(n = n, k = k, second = TRUE, third = TRUE)
# Compute the model output:
Y <- sobol_Fun(A)
# Compute the Sobol' indices for the dummy parameter:
sobol_dummy(Y = Y, params = colnames(data.frame(A)), R = R, n = n)

[Package sensobol version 0.2.2 Index]