Sensitivity
Run sensitivity analyses on a model.
ModelManager.GSAMethod — Type
ModelManager.GSASampling — Type
GSASamplingAbstract type for global sensitivity analysis sampling results.
ModelManager.MOAT — Type
MOAT <: GSAMethodMorris One-At-A-Time global sensitivity analysis.
Fields
lhs_variation::LHSVariation
Examples
MOAT() # default 15 base points
MOAT(10) # 10 base points
MOAT(10; add_noise=true)ModelManager.MOATSampling — Type
MOATSampling <: GSASamplingResult of a MOAT sensitivity analysis.
ModelManager.RBD — Type
RBD <: GSAMethodRandom Balance Design global sensitivity analysis.
Fields
rbd_variation::RBDVariationnum_harmonics::Int
Examples
RBD(15)
RBD(15; num_harmonics=10)
RBD(15; use_sobol=false)ModelManager.RBDSampling — Type
RBDSampling <: GSASamplingResult of an RBD sensitivity analysis.
ModelManager.SobolMM — Type
SobolMMASCII alias for Sobolʼ.
ModelManager.SobolSampling — Type
SobolSampling <: GSASamplingResult of a Sobolʼ sensitivity analysis.
ModelManager.Sobolʼ — Type
Sobolʼ <: GSAMethodSobol' variance-based global sensitivity analysis.
The ʼ (rasp) symbol avoids conflict with the Sobol module. Type \rasp<tab> in VS Code. SobolMM is provided as a plain-ASCII alias.
Fields
sobol_variation::SobolVariationsobol_index_methods::NamedTuple{(:first_order,:total_order),Tuple{Symbol,Symbol}}
Examples
Sobolʼ(15)
Sobolʼ(15; sobol_index_methods=(first_order=:Jansen1999, total_order=:Jansen1999))
Sobolʼ(15; skip_start=true)Base.run — Method
run(method::GSAMethod, inputs::InputFolders, avs; functions, kwargs...)
run(method::GSAMethod, reference::AbstractMonad, avs; functions, kwargs...)Run a global sensitivity analysis and return a GSASampling result.
kwargs are forwarded to run(::Sampling; ...) and from there to the simulator hooks — pass any simulator-specific options here.
ModelManager.calculateGSA! — Method
calculateGSA!(gsa_sampling, functions; recompute=false)
calculateGSA!(gsa_sampling, f; recompute=false)Calculate sensitivity indices for functions (or for the single measurement f) and file them in gsa_sampling.results under their labels — see gsaLabels.
A measurement whose results are already present is skipped, so adding a quantity to an analysis costs only the new one: run(method, spec; functions=[q1]) followed by calculateGSA!(gsa, [q1, q2]) reads each simulation's output for q2 alone.
Results accumulate. A measurement absent from functions keeps whatever it produced earlier — that is what makes adding a quantity cheap, and its indices are not stale, having been computed from this same sampling. What recompute replaces is the labels of the measurements you do name, so a reducer that drops or renames a key leaves nothing behind; it never prunes ones you do not name. empty!(gsa_sampling.results) is how you start over.
Keywords
recompute: evaluate even where results already exist, replacing every label that measurement owns rather than merging into them — so a reducer that drops or renames a key leaves nothing stale behind. Needed when the measurement itself has changed, because nothing can detect that — redefining a function's body in place leaves it indistinguishable from the one already evaluated, the same reason aQoI'sstoreddefaults to:never.
Errors
Two entries of functions that produce the same label — most easily two QoIs with the same name — are refused, since one would silently replace the other. Nothing is filed when this happens; the whole call is rejected before any result is stored.
ModelManager.getMonadIDDataFrame — Method
getMonadIDDataFrame(gsa_sampling::GSASampling)Return the DataFrame of monad IDs that define the sampling scheme.
ModelManager.gsaLabels — Method
gsaLabels(gsa_sampling::GSASampling)The labels of the sensitivity analyses computed on gsa_sampling, sorted.
One label is not one functions= entry. A QoI whose reduce returns a Dict or NamedTuple yields one analysis per key, labelled "<qoi name>.<key>"; a Real yields one labelled with the QoI's name. Each label indexes gsa_sampling.results.
ModelManager.methodString — Method
methodString(gsa_sampling::GSASampling)Return a lowercase string identifier for the GSA method (e.g. "moat", "sobol").
ModelManager.monadIDs — Method
monadIDs(gsa_sampling::GSASampling)Return the IDs of the monads evaluated in the sensitivity analysis.
These are the same monads that getMonadIDDataFrame reports, flattened and deduplicated: the data frame arranges them in the shape the method's design requires — one column per factor for MOAT, for instance — while this gives the flat set, which is what monadsTable and the deletion functions want.
ModelManager.simulationIDs — Method
simulationIDs(gsa_sampling::GSASampling)Return the simulation IDs run in the sensitivity analysis.