Estimation index | Diagnostics | Model comparison | Technical Reference
Influence diagnostics identify observations or prior components that materially affect fitted parameters, local uncertainty, or predictive accuracy. They are investigation tools, not automatic deletion rules. Extreme floods, paleoflood intervals, perception thresholds, and regional-skew information can be influential precisely because they contain the tail information the analysis was designed to use.
For posterior draws
Pareto-smoothed importance sampling fits a generalized Pareto distribution to the largest excess ratios. The fitted shape
BayesianAnalysis.ComputeInfluenceDiagnostics() attaches the cached ParetoK and pointwise ELPD values to DataComponent metadata. Default Bayesian completion evaluates the pointwise likelihood once per retained draw, shares the transient matrix between WAIC and PSIS, and retains only the
For loo 2.10.0 limit
The 40-draw external fixture has threshold r_eff = 1 for tail-length selection and does not automatically perform exact or moment-matched refits.
At an MLE or MAP point
A first-order one-case deletion displacement is proportional to GetObservationInfluence() returns each component standardized by its local standard error:
GetCooksDistance() returns the score quadratic
MLE uses the data-likelihood Hessian; MAP uses the full posterior Hessian but still uses a data score in (INF.3). These are local approximations and do not refit after deletion. The familiar linear-model suggestions CovarianceStatus; unavailable uncertainty must not be interpreted as zero influence.
Grouped threshold contributions require care. A pointwise unit with count
For pointwise moment vector
GeneralizedMethodOfMoments.GetLeverageDiagnostics() reports observation Cook fit influence and variance influence as
where
The diagnostic objective in (INF.6b) always uses the half-quadratic moment term, whether or not a penalty is enabled. This keeps observation scores, bread, Cook influence, and penalty curvature on one scale. It does not alter the optimizer's public Q convention, its estimating gradient, fitted parameters, penalty Hessian, or reported GMM covariance.
For Bulletin 17C grouped components, row-level Leverage is the sum
The seven-point Log10-Normal fixture is independently reproduced by R gmm 1.9.1 and sandwich 3.1.2. BestFit matches every observation and the aggregate values
GeneralizedMethodOfMoments.GetInfluenceDiagnostics() is a legacy compatibility path that stores a different GMM Cook-like scalar in the PSIS-oriented ObservationInfluence.ParetoK member. Both overloads are marked [Obsolete] with a non-error compatibility warning. Their Pareto thresholds and reliability summaries are not GMM diagnostics. Use GetLeverageDiagnostics() for labeled fit/variance/combined GMM diagnostics or GetCooksDistance() for the raw Cook-like values; do not interpret the legacy compatibility value as Pareto
PriorInfluenceDiagnostics evaluates PointwisePriorLogLikelihood over every thinEvery-th posterior draw. For component
It also computes the heuristic magnitude ratio
IsPriorInfluential uses
For parameter
clamped to ModelParameter.PriorDistribution; quantile, Jeffreys, coupled, and spatial prior components in (INF.7) are absent from (INF.9). The name “precision share” should therefore be read as a marginal heuristic, not a formal fraction of posterior information.
The AutoRegressive, MovingAverage, and ARIMA pointwise prior methods classify the optional Jeffreys scale term as JeffreysScalePrior, separately from the marginal ParameterPrior components. Type-filtered summaries can therefore distinguish those contributions.
LeverageDiagnostics evaluates the posterior Hessian at the supplied MCMC MAP state or MAP optimizer result. For observation
where
For prior component
Here
This is an additive ranking index, not classical hat-matrix leverage or a conserved information decomposition. It is not expected to sum to
The deterministic Log10-Normal tests establish the intended interpretation. A wide centered Gaussian prior has negligible fit and variance influence; a narrow centered prior has negligible fit influence and strong variance influence; and a narrow prior shifted by
For the displaced narrow-prior fixture, the historical comparison replacing
Numerical differentiation can encounter bounds or discontinuous branches. MLE/MAP covariance failures are explicit; other diagnostic containers can be empty when their prerequisites are unavailable. A regularized covariance remains an approximation. Retain the raw values, fitted model, finite-difference configuration, and covariance status when using rankings in an engineering review.
The retained GMM deletion-magnitude comparison is an accepted limitation: one-step influence is not calibrated to exact case deletion. The supported outlier fixture establishes ranking of a deliberately influential observation. A large score is a reason to investigate the record and refit a scientifically meaningful alternative, not a numerical estimate of the exact deletion effect.
private static (
InfluenceDiagnostics Influence,
PriorInfluenceDiagnostics PriorInfluence,
LeverageDiagnostics Leverage) ComputeBayesianDiagnostics(
BayesianAnalysis analysis)
{
if (!analysis.IsEstimated || analysis.Results is null)
{
throw new InvalidOperationException(
"Run the Bayesian analysis before computing diagnostics.");
}
return (
analysis.ComputeInfluenceDiagnostics(),
analysis.ComputePriorInfluenceDiagnostics(thinEvery: 10),
analysis.ComputeLeverageDiagnostics());
}Use the returned metadata to locate observations in the source record, then investigate chronology, measurement quality, censoring definitions, and model assumptions. Do not delete an observation solely because it ranks highly. Refit-with-and-without sensitivity analysis should preserve a documented scientific reason and distinguish data correction from robustness analysis.
- Confirm that pointwise components correspond to independent deletion units.
- Inspect each Pareto
$k$ against the draw-count reliability limit before using PSIS results. - Distinguish exact refitting from first-order score approximations.
- Never interpret zero arrays without checking Hessian/covariance failure.
- Treat prior log-magnitude and marginal precision ratios as heuristics.
- Use GMM Cook measures only on the GMM scale; never relabel the legacy compatibility value as Pareto
$k$ . - Preserve hydrologic context: an influential extreme may be correct and indispensable.
- Report sensitivity of design quantiles, not only parameter displacement.
Fast tests exercise serialization, draw-count threshold persistence, legacy XML shape, sorting, percentages, component mapping, and UI labels. Focused Log10-Normal methods verify MAP prior regimes, GMM penalty regimes, sample-size attenuation, MAP curvature materiality, and pointwise/aggregate parity with R gmm. Six exact R loo 2.10.0 methods verify PSIS identities, corrected BestFit aggregate and pointwise output, every tail-regime weight and Pareto InfluenceDiagnostics, ObservationInfluence, PriorInfluenceDiagnostics, PriorComponentSummary, LeverageDiagnostics, MaximumLikelihood.GetObservationInfluence, MaximumLikelihood.GetCooksDistance, matching MAP methods, and GeneralizedMethodOfMoments.GetInfluenceDiagnostics.
[1] R. D. Cook, “Detection of influential observation in linear regression,” Technometrics, vol. 19, no. 1, pp. 15–18, 1977.
[2] S. Chatterjee and A. S. Hadi, “Influential observations, high leverage points, and outliers in linear regression,” Statistical Science, vol. 1, no. 3, pp. 379–393, 1986.
[3] A. Vehtari et al., “Pareto smoothed importance sampling,” Journal of Machine Learning Research, vol. 25, no. 72, pp. 1–58, 2024.