sens.var.samp: Variance-based sensitivities of a deterministic model

Description Usage Arguments Value Author(s)

View source: R/sens.R

Description

Function to calculate the first order variance-based sensitivity coefficients from a parameter sample and the corresponding result sample.

Usage

1
2
sens.var.samp(parsamp,ressamp,nbin=NA,method="smooth",order=2,
              bandwidth=1,span=0.75,sd.rel=0.1,plot=F)

Arguments

parsamp

matrix containing the parameter sample (each row corresponds to a sample point)

ressamp

vector (of only one result per parameter sample point) or matrix of results corresponding to the parameter sample (each row provides the results corresponding to the parameter values in the same row of parsamp)

nbin

number of quantile intervals for which the conditional means are calculated, default is the square root of the sample size

method

"smooth", "loess", "glkerns", "lokerns", "lpepa", "lpridge": routine to be used for smoothing

order

order of local regression polynomial or of kernel

bandwidth

method="lpepa" or method="lpdidge" only: bandwidth of the smoothing algorithm

span

method="loess" only: fraction of points used for local regression

sd.rel

method="smooth" only: standard deviation of normal distribution of smoothing algorithm relative to the 99% quantile interval

plot

logical variable indicating if a scatter plot of the relationship between parameter and model output should be plotted

Value

Returns a list with two elements:

var

vector with the total variance of each column (each model output) of the ressamp matrix

var.cond.E

matrix with the variance of the conditional expected value of each parameter (columns) and each model output (rows)

Author(s)

Peter Reichert <peter.reichert@eawag.ch>


baccione-eawag/EawagSchoolTools documentation built on Dec. 19, 2021, 6:38 a.m.