sqi_sensitivity: Sensitivity Analysis for SQI

View source: R/statistics.R

sqi_sensitivityR Documentation

Sensitivity Analysis for SQI

Description

Quantifies the contribution of each soil variable to the overall Soil Quality Index by a leave-one-out approach: each variable is removed in turn and the resulting index is compared to the full index. A larger change indicates a higher-sensitivity (more important) variable.

Usage

sqi_sensitivity(
  scored,
  config,
  group_cols = "LandUse",
  method = c("linear", "fuzzy", "entropy", "topsis"),
  mds_vars = NULL
)

Arguments

scored

A scored data frame from score_all.

config

A sqi_config object.

group_cols

Character vector of grouping columns.

method

Character. Which indexing method to use for sensitivity analysis: "linear" (default), "fuzzy", "entropy", or "topsis".

mds_vars

Character vector of MDS variable names. If NULL, all config variables are used.

Value

A data frame with columns variable, mean_change (mean absolute change in SQI when variable is removed), sd_change, and relative_importance (0–1, normalised).

References

Saltelli, A., Ratto, M., Andres, T., Campolongo, F., Cariboni, J., Gatelli, D., Saisana, M., & Tarantola, S. (2008). Global Sensitivity Analysis: The Primer. John Wiley & Sons, Chichester. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1002/9780470725184")}

Examples

data(soil_data)
cfg <- make_config(
  variable = c("pH","EC","BD","OC","MBC","Clay"),
  type     = c("opt","less","less","more","more","opt"),
  opt_low  = c(6.0, NA, NA, NA, NA, 20),
  opt_high = c(7.0, NA, NA, NA, NA, 35)
)
scored  <- score_all(soil_data, cfg, group_cols = c("LandUse","Depth"))
sa      <- sqi_sensitivity(scored, cfg, group_cols = c("LandUse","Depth"))
print(sa)


SQIpro documentation built on April 20, 2026, 5:06 p.m.