Skip to main content

Uncertainty Quantification of Complex System Models: Bayesian Analysis

  • Reference work entry
  • First Online:

Abstract

This chapter summarizes the main elements of Bayesian probability theory to help reconcile dynamic environmental system models with observations, including prediction in space (interpolation), prediction in time (forecasting), assimilation of data, and inference of the model parameters. Special attention is given to the treatment of parameter uncertainty (first-order approximations and Bayesian intervals), the prior distribution, the formulation of the likelihood function (using first-principles), the marginal likelihood, and sampling techniques used to estimate the posterior target distribution. This includes rejection sampling, importance sampling, and recent developments in Markov chain Monte Carlo simulation to sample efficiently complex and/or high-dimensional target distributions, including limits of acceptability. We illustrate the application of Bayes’ theorem and inference using three illustrative examples involving the flow and storage of water in the surface and subsurface. At least some level of calibration of these models is required to match their output with observations of system behavior and response. Algorithmic recipes of the different methods are provided to simplify implementation and use of Bayesian analysis.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   599.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Hardcover Book
USD   799.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  • B.C. Bates, E.P. Campbell, A Markov chain Monte Carlo scheme for parameter estimation and inference in conceptual rainfall-runoff modeling. Water Resour. Res. 37(4), 937–947 (2001)

    Article  Google Scholar 

  • T. Bayes, R. Price, An essay towards solving a problem in the doctrine of chance. By the late Rev. Mr. Bayes, communicated by Mr. Price, in a letter to John Canton, A.M.F.R.S. Philos. Trans. R. Soc. Lond. 53(0), 370–418 (1763). https://doi.org/10.1098/rstl.1763.0053

    Article  Google Scholar 

  • J.O. Berger, Statistical Decision Theory and Bayesian Analysis (Springer, New York, 1985)

    Book  Google Scholar 

  • J.O. Berger, J.M. Bernardo, D. Sun, The formal definition of reference priors. Ann. Stat. 37(2), 905–938 (2009). https://doi.org/10.1214/07-AOS587

    Article  Google Scholar 

  • J.M. Bernardo, Reference posterior distributions for Bayesian inference (with discussion). J. R. Stat. Soc. Ser. B 41, 113–147 (1979)

    Google Scholar 

  • K. Beven, A manifesto for the equifinality thesis. J. Hydrol. 320(1), 18–36 (2006)

    Article  Google Scholar 

  • K.J. Beven, A.M. Binley, The future of distributed models: Model calibration and uncertainty prediction. Hydrol. Process. 6, 279–298 (1992)

    Article  Google Scholar 

  • K.J. Beven, A.M. Binley, GLUE: 20 years on. Hydrol. Process. 28, 5879–5918 (2014). https://doi.org/10.1002/hyp.10082

    Article  Google Scholar 

  • S. Blazkova, K.J. Beven, A limits of acceptability approach to model evaluation and uncertainty estimation in flood frequency estimation by continuous simulation: Skalka catchment, Czech Republic. Water Resour. Res. 45, W00B16 (2009). https://doi.org/10.1029/2007WR006726

    Article  Google Scholar 

  • G.E.P. Box, G.C. Tiao, Bayesian Inference in Statistical Analysis (Wiley, New York, 1992), 588 pp

    Book  Google Scholar 

  • S.P. Brooks, A. Gelman, General methods for monitoring convergence of iterative simulations. J. Comput. Graph. Stat. 7, 434–455 (1998)

    Google Scholar 

  • M. Clark, D. Kavetski, F. Fenicia, Pursuing the method of multiple working hypotheses for hydrological modeling. Water Resour. Res. 47(9), 1–16 (2011). https://doi.org/10.1029/2010WR009827

    Article  Google Scholar 

  • S. Dean, J.E. Freer, K.J. Beven, A.J. Wade, D. Butterfield, Uncertainty assessment of a process-based integrated catchment model of phosphorus (INCA-P). Stoch. Env. Res. Risk A. 23, 991–1010 (2009). https://doi.org/10.1007/s00477-008-0273-z

    Article  Google Scholar 

  • Q. Duan, S. Sorooshian, V. Gupta, Effective and efficient global optimization for conceptual rainfall-runoff models. Water Resour. Res. 28(4), 1015–1031 (1992)

    Article  Google Scholar 

  • G. Evin, D. Kavetski, M. Thyer, G. Kuczera, Pitfalls and improvements in the joint inference of heteroscedasticity and autocorrelation in hydrological model calibration. Water Resour. Res. 49, 4518–4524 (2013). https://doi.org/10.1002/wrcr.20284

    Article  Google Scholar 

  • C. Fernandez, M.J.F. Steel, On Bayesian modeling of fat tails and skewness. J. Am. Stat. Assoc. 93, 359–371 (1998)

    Google Scholar 

  • J. Freer, H. McMillan, J.J. McDonnell, K.J. Beven, Constraining dynamic TOPMODEL responses for imprecise water table information using fuzzy rule based performance measures. J. Hydrol. 291, 254–277 (2004)

    Article  Google Scholar 

  • A.G. Gelman, D.B. Rubin, Inference from iterative simulation using multiple sequences. Stat. Sci. 7, 457–472 (1992)

    Article  Google Scholar 

  • A.G. Gelman, G.O. Roberts, W.R. Gilks, Bayesian Statistics (Oxford University Press, Oxford, 1996), pp. 599–608

    Google Scholar 

  • J. Geweke, Evaluating the accuracy of sampling-based approaches to the calculation of posterior moments, in Bayesian Statistics 4, ed. by J.M. Bernardo, J.O. Berger, A.P. Dawid, A.F.M. Smith (Oxford Oxford University Press, 1992), pp. 169–193

    Google Scholar 

  • W.R. Gilks, G.O. Roberts, Strategies for improving MCMC, in Markov Chain Monte Carlo in Practice, ed. by W.R. Gilks, S. Richardson, D.J. Spiegelhalter (Chapman & Hall, London, 1996), pp. 89–114

    Google Scholar 

  • W.R. Gilks, G.O. Roberts, E.I. George, Adaptive direction sampling. Underst. Stat. 43, 179–189 (1994)

    Google Scholar 

  • H.V. Gupta, T. Wagener, Y. Liu, Reconciling theory with observations: Elements of a diagnostic approach to model evaluation. Hydrol. Process. 22(18), 3802–3813 (2008)

    Article  Google Scholar 

  • H. Haario, E. Saksman, J. Tamminen, Adaptive proposal distribution for random walk Metropolis algorithm. Comput. Stat. 14, 375–395 (1999)

    Article  Google Scholar 

  • H. Haario, E. Saksman, J. Tamminen, An adaptive Metropolis algorithm. Bernoulli 7, 223–242 (2001)

    Article  Google Scholar 

  • H. Haario, E. Saksman, J. Tamminen, Componentwise adaptation for high dimensional MCMC. Stat. Comput. 20, 265–274 (2005)

    Article  Google Scholar 

  • H. Haario, M. Laine, A. Mira, E. Saksman, DRAM: Efficient adaptive MCMC. Stat. Comput. 16, 339–354 (2006)

    Article  Google Scholar 

  • H. Hastings, Monte Carlo sampling methods using Markov chains and their applications. Biometrika 57, 97–109 (1970)

    Article  Google Scholar 

  • T.J. Heimovaara, W. Bouten, A computer-controlled 36-channel time domain reflectometry system for monitoring soil water contents. Water Resour. Res. 26, 2311–2316 (1990). https://doi.org/10.1029/WR026i010p02311

    Article  Google Scholar 

  • J. Hoeting, D. Madigan, A. Raftery, C. Volinsky, Bayesian model averaging: A tutorial. Stat. Sci. 14(4), 382–417 (1999)

    Article  Google Scholar 

  • H. Jeffreys, An invariant form for the prior probability in estimation problems. Proc. R. Soc. Lond. A Math. Phys. Sci. 186(1007), 453–461 (1946). https://doi.org/10.1098/rspa.1946.0056

    Article  Google Scholar 

  • D. Kavetski, G. Kuczera, S.W. Franks, Bayesian analysis of input uncertainty in hydrological modeling: 1. Theory. Water Resour. Res. 42(3), W03407 (2006a). https://doi.org/10.1029/2005WR004368

    Article  Google Scholar 

  • D. Kavetski, G. Kuczera, S.W. Franks, Bayesian analysis of input uncertainty in hydrological modeling: 2. Application. Water Resour. Res. 42(3), W03408 (2006b). https://doi.org/10.1029/2005WR004376

    Article  Google Scholar 

  • K. Keesman, Membership-set estimation using random scanning and principal component analysis. Math. Comput. Simul. 32, 535–543 (1990)

    Article  Google Scholar 

  • T. Krueger, J.N. Quinton, J. Freer, C.J. Macleod, G.S. Bilotta, R.E. Brazier, P.M. Haygarth, Uncertainties in data and models to describe event dynamics of agricultural sediment and phosphorus transfer. J. Environ. Qual. 38(3), 1137–1148 (2009)

    Article  Google Scholar 

  • G. Kuczera, Improved parameter inference in catchment models, 1. Evaluating parameter uncertainty. Water Resour. Res. 19(5), 1151–1162 (1983). https://doi.org/10.1029/WR019i005p01151

    Article  Google Scholar 

  • G. Kuczera, D. Kavetski, S. Franks, M. Thyer, Towards a Bayesian total error analysis of conceptual rainfall-runoff models: Characterising model error using storm-dependent parameters. J. Hydrol. 331(1), 161–177 (2006)

    Article  Google Scholar 

  • E. Laloy, J.A. Vrugt, High-dimensional posterior exploration of hydrologic models using multiple-try DREAM(ZS) and high-performance computing. Water Resour. Res. 48, W01526 (2012). https://doi.org/10.1029/2011WR010608

    Article  Google Scholar 

  • J.S. Liu, F. Liang, W.H. Wong, The multiple-try method and local optimization in metropolis sampling. J. Am. Stat. Assoc. 95(449), 121–134 (2000). https://doi.org/10.2307/2669532

    Article  Google Scholar 

  • Y. Liu, J.E. Freer, K.J. Beven, P. Matgen, Towards a limits of acceptability approach to the calibration of hydrological models: Extending observation error. J. Hydrol. 367, 93–103 (2009). https://doi.org/10.1016/j.jhydrol.2009.01.016

    Article  Google Scholar 

  • H. McMillan, J. Freer, F. Pappenberger, T. Krueger, M. Clark, Impacts of uncertain river flow data on rainfall-runoff model calibration and discharge predictions. Hydrol. Process. 24(10), 1270–1284 (2010)

    Google Scholar 

  • N. Metropolis, A.W. Rosenbluth, M.N. Rosenbluth, A.H. Teller, E. Teller, Equation of state calculations by fast computing machines. J. Chem. Phys. 21, 1087–1092 (1953)

    Article  Google Scholar 

  • J.E. Nash, A unit hydrograph study with particular reference to British catchments. Proc. Inst. Civ. Eng. 17, 249–282 (1960)

    Google Scholar 

  • J.E. Nash, J.V. Sutcliffe, River flow forecasting through conceptual models part I – A discussion of principles. J. Hydrol. 10(3), 282–290 (1970)

    Article  Google Scholar 

  • T. Page, K.J. Beven, J. Freer, A. Jenkins, Investigating the uncertaintyin predicting responses to atmospheric deposition using the model of acidification of groundwater in catchments (MAGIC) within a generalised likelihood uncertainty estimation (GLUE) framework. Water Soil Air Pollut. 142, 71–94 (2003)

    Article  Google Scholar 

  • T. Page, K.J. Beven, D. Whyatt, Predictive capability in estimating changes in water quality: Long-term responses to atmospheric deposition. Water Soil Air Pollut. 151, 215–244 (2004)

    Article  Google Scholar 

  • T. Page, K.J. Beven, J. Freer, Modelling the chloride signal at the Plynlimon catchments, Wales using a modified dynamic TOPMODEL. Hydrol. Process. 21, 292–307 (2007)

    Article  Google Scholar 

  • F. Pappenberger, K. Beven, M. Horritt, S. Blazkova, Uncertainty in the calibration of effective roughness parameters in HEC-RAS using inundation and downstream level observations. J. Hydrol. 302, 46–69 (2005)

    Article  Google Scholar 

  • F. Pappenberger, K. Frodsham, K.J. Beven, R. Romanovicz, P. Matgen, Fuzzy set approach to calibrating distributed flood inundation models using remote sensing observations. Hydrol. Earth Syst. Sci. 11(2), 739–752 (2007)

    Article  Google Scholar 

  • K.V. Price, R.M. Storn, J.A. Lampinen, Differential Evolution, A Practical Approach to Global Optimization (Springer, Berlin, 2005)

    Google Scholar 

  • V.C. Radu, J. Rosenthal, C. Yang, Learn from the thy neighbor: Parallel-chain and regional adaptive MCMC. J. Am. Stat. Assoc. 104(488), 1454–1466 (2009)

    Article  Google Scholar 

  • A.E. Raftery, S.M. Lewis, One long run with diagnostics: Implementation strategies for Markov chain Monte Carlo. Stat. Sci. 7, 493–497 (1992)

    Article  Google Scholar 

  • A.E. Raftery, T. Gneiting, F. Balabdaoui, M. Polakowski, Using Bayesian model averaging to calibrate forecast ensembles. Mon. Weather Rev. 133, 1155–1174 (2005)

    Article  Google Scholar 

  • P. Reichert, J. Mieleitner, Analyzing input and structural uncertainty of nonlinear dynamic models with stochastic, timeâĂŘdependent parameters. Water Resour. Res. 45, W10402 (2009). https://doi.org/10.1029/2009WR007814

    Article  Google Scholar 

  • B. Renard, D. Kavetski, E. Leblois, M. Thyer, G. Kuczera, S.W. Franks, Toward a reliable decomposition of predictive uncertainty in hydrological modeling: Characterizing rainfall errors using conditional simulation. Water Resour. Res. 47(11), W11516 (2011). https://doi.org/10.1029/2011WR010643

    Article  Google Scholar 

  • C.P. Roberts, G. Casella, Monte Carlo Statistical Methods, 2nd edn. (Springer, New York, 2004)

    Book  Google Scholar 

  • G.O. Roberts, W.R. Gilks, Convergence of adaptive direction sampling. J. Multivar. Anal. 49, 287–298 (1994)

    Article  Google Scholar 

  • G.O. Roberts, J.S. Rosenthal, Coupling and ergodicity of adaptive Markov chain Monte Carlo algorithms. J. Appl. Probab. 44, 458–475 (2007)

    Article  Google Scholar 

  • G.O. Roberts, A. Gelman, W.R. Gilks, Weak convergence and optimal scaling of random walk Metropolis algorithms. Ann. Appl. Probab. 7, 110–120 (1997)

    Article  Google Scholar 

  • M. Sadegh, J.A. Vrugt, Approximate Bayesian computation using Markov chain Monte Carlo simulation: DREAM(ABC). Water Resour. Res. 50 (2014). https://doi.org/10.1002/2014WR015386

    Article  Google Scholar 

  • M. Sadegh, J.A. Vrugt, C. Xu, E. Volpi, The stationarity paradigm revisited: Hypothesis testing using diagnostics, summary metrics, and DREAM(ABC). Water Resour. Res. 51, 9207–9231 (2015). https://doi.org/10.1002/2014WR016805

    Article  Google Scholar 

  • M.G. Schaap, F.J. Leij, M.T. van Genuchten, Neural network analysis for hierarchical prediction of soil water retention and saturated hydraulic conductivity. Soil Sci. Soc. Am. J. 62, 847–855 (1998)

    Article  Google Scholar 

  • M.G. Schaap, F.J. Leij, M.T. van Genuchten, Rosetta: A computer program for estimating soil hydraulic parameters with hierarchical pedotransfer functions. J. Hydrol. 251, 163–176 (2001)

    Article  Google Scholar 

  • B. Scharnagl, J.A. Vrugt, H. Vereecken, M. Herbst, Bayesian inverse modeling of soil water dynamics at the field scale: Using prior information about the soil hydraulic properties. Hydrol. Earth Syst. Sci. 15, 3043–3059 (2011). https://doi.org/10.5194/hess-15-3043-2011

    Article  Google Scholar 

  • B. Scharnagl, S.C. Iden, W. Durner, H. Vereecken, M. Herbst, Inverse modelling of in situ soil water dynamics: Accounting for heteroscedastic, autocorrelated, and non-Gaussian distributed residuals. Hydrol. Earth Syst. Sci. Discuss. 12, 2155–2199 (2015)

    Article  Google Scholar 

  • A. Schöniger, T. Wöhling, L. Samaniego, W. Nowak, Model selection on solid ground: Rigorous comparison of nine ways to evaluate Bayesian model evidence. Water Resour. Res. 50(12), W10530, 9484–9513 (2014). https://doi.org/10.1002/2014WR016062

    Article  Google Scholar 

  • G. Schoups, J.A. Vrugt, A formal likelihood function for parameter and predictive inference of hydrologic models with correlated, heteroscedastic and non-Gaussian errors. Water Resour. Res. 46, W10531 (2010). https://doi.org/10.1029/2009WR008933

    Article  Google Scholar 

  • J. Šimůnek, M. Šejna, H. Saito, M. Sakai, M.T. van Genuchten, The HYDRUS-1D Software Package for Simulating the One-Dimensional Movement of Water, Heat and Multiple Solutes in Variably-Saturated Media (Version 4.0) (Department of Environmental Sciences, University of California Riverside, Riverside, 2008)

    Google Scholar 

  • T. Smith, A. Sharma, L. Marshall, R. Mehrotra, S. Sisson, Development of a formal likelihood function for improved Bayesian inference of ephemeral catchments. Water Resour. Res. 46, W12551 (2010). https://doi.org/10.1029/2010WR009514

    Article  Google Scholar 

  • S. Sorooshian, J.A. Dracup, Stochastic parameter estimation procedures for hydrologic rainfall-runoff models: Correlated and heteroscedastic error cases. Water Resour. Res. 16(2), 430–442 (1980)

    Article  Google Scholar 

  • S.M. Stigler, Who discovered Bayes’s theorem? Am. Stat. 37(4 Part 1), 290–296 (1983)

    Article  Google Scholar 

  • R. Storn, K. Price, A simple and efficient heuristic for global optimization over continuous spaces. J. Glob. Optim. 11, 341–359 (1997)

    Article  Google Scholar 

  • C.J.F. ter Braak, A Markov chain Monte Carlo version of the genetic algorithm differential evolution: Easy Bayesian computing for real parameter spaces. Stat. Comput. 16, 239–249 (2006)

    Article  Google Scholar 

  • C.J.F. ter Braak, J.A. Vrugt, Differential evolution Markov chain with snooker updater and fewer chains. Stat. Comput. 18(4), 435–446 (2008). https://doi.org/10.1007/s11222-008-9104-9

    Article  Google Scholar 

  • M. Thiemann, M. Trosset, H. Gupta, S. Sorooshian, Bayesian recursive parameter estimation for hydrologic models. Water Resour. Res. 37(10), 2521–2535 (2001)

    Article  Google Scholar 

  • G.C. Topp, J.L. Davis, A.P. Annan, Electromagnetic determination of soil water content: Measurements in coaxial transmission lines. Water Resour. Res. 16, 574–582 (1980). https://doi.org/10.1029/WR016i003p00574

    Article  Google Scholar 

  • M.T. van Genuchten, A closed-form equation for predicting the hydraulic conductivity of unsaturated soils. Soil Sci. Soc. Am. J. 44(5), 892–898 (1980). https://doi.org/10.2136/sssaj1980.03615995004400050002x

    Article  Google Scholar 

  • E. Volpi, G. Schoups, G. Firmani, J.A. Vrugt, Sworn testimony of the model evidence: Gaussian Mixture Importance (GAME) sampling. Water Resour. Res. 53, 6133–6158 (2017). https://doi.org/10.1002/2016WR020167

    Article  Google Scholar 

  • J.A. Vrugt, Markov chain Monte Carlo simulation using the DREAM software package: Theory, concepts, and MATLAB implementation. Environ. Model. Softw. 75, 273–316 (2016). https://doi.org/10.1016/j.envsoft.2015.08.013

    Article  Google Scholar 

  • J.A. Vrugt, K.J. Beven, Embracing equifinality with efficiency: Limits of acceptability sampling using the DREAM(LOA) algorithm. J. Hydrol. 559, 954–971 (2018). https://doi.org/10.1016/j.jhydrol.2018.02.026, In Press

    Article  Google Scholar 

  • J.A. Vrugt, E. Laloy, Reply to comment by Chu et al. on High-dimensional posterior exploration of hydrologic models using multiple-try DREAMtext(ZS) and high-performance computing. Water Resour. Res. 50, 2781–2786 (2014). https://doi.org/10.1002/2013WR014425

    Article  Google Scholar 

  • J.A. Vrugt, B.A. Robinson, Treatment of uncertainty using ensemble methods: Comparison of sequential data assimilation and Bayesian model averaging. Water Resour. Res. 43, W01411 (2007). https://doi.org/10.1029/2005WR004838

    Article  Google Scholar 

  • J.A. Vrugt, M. Sadegh, Toward diagnostic model calibration and evaluation: Approximate Bayesian computation. Water Resour. Res. 49 (2013). https://doi.org/10.1002/wrcr.20354

    Article  Google Scholar 

  • J.A. Vrugt, C.J.F. ter Braak, DREAM(D): An adaptive Markov chain Monte Carlo simulation algorithm to solve discrete, noncontinuous, and combinatorial posterior parameter estimation problems. Hydrol. Earth Syst. Sci. 15, 3701–3713 (2011). https://doi.org/10.5194/hess-15-3701-2011

    Article  Google Scholar 

  • J.A. Vrugt, H.V. Gupta, W. Bouten, S. Sorooshian, A Shuffled Complex Evolution Metropolis algorithm for optimization and uncertainty assessment of hydrologic model parameters. Water Resour. Res. 39(8), 1201 (2003). https://doi.org/10.1029/2002WR001642

    Article  Google Scholar 

  • J.A. Vrugt, C.G.H. Diks, W. Bouten, H.V. Gupta, J.M. Verstraten, Improved treatment of uncertainty in hydrologic modeling: Combining the strengths of global optimization and data assimilation. Water Resour. Res. 41(1), W01017 (2005). https://doi.org/10.1029/2004WR003059

    Article  Google Scholar 

  • J.A. Vrugt, C.J.F. ter Braak, M.P. Clark, J.M. Hyman, B.A. Robinson, Treatment of input uncertainty in hydrologic modeling: Doing hydrology backward with Markov chain Monte Carlo simulation. Water Resour. Res. 44, W00B09 (2008). https://doi.org/10.1029/2007WR006720

    Article  Google Scholar 

  • J.A. Vrugt, C.J.F. ter Braak, C.G.H. Diks, D. Higdon, B.A. Robinson, J.M. Hyman, Accelerating Markov chain Monte Carlo simulation by differential evolution with self-adaptive randomized subspace sampling. Int. J. Nonlinear Sci. Numer. Simul 10(3), 273–290 (2009)

    Article  Google Scholar 

  • L. Wasserman, Bayesian model selection and model averaging. J. Math. Psychol. 44(1), 92–107 (2000). https://doi.org/10.1006/jmps.1999.1278

    Article  Google Scholar 

  • I.K. Westerberg, J.-L. Guerrero, P.M. Younger, K.J. Beven, J. Seibert, S. Halldin, J.E. Freer, C.-Y. Xu, Calibration of hydrological models using flow-duration curves. Hydrol. Earth Syst. Sci. 15, 2205–2227 (2011). https://doi.org/10.5194/hess-15-2205-2011

    Article  Google Scholar 

  • J. Yang, P. Reichert, K.C. Abbaspour, Bayesian uncertainty analysis in distributed hydrologic modeling: A case study in the Thur River basin (Switzerland). Water Resour. Res. 43, W10401 (2007). https://doi.org/10.1029/2006WR005497

    Article  Google Scholar 

  • M. Ye, P. Meyer, S.P. Neuman, On model selection criteria in multimodel analysis. Water Resour. Res. 44, 1–12 (2008). https://doi.org/10.1029/2008WR006803

    Article  Google Scholar 

  • S.L. Zabell, The rule of succession. Erkenntnis 31(2–3), 283–321 (1989)

    Article  Google Scholar 

Download references

Acknowledgments

The first author is supported by funding from the UC-Lab Fees Research Program Award 237285. The material presented in this chapter is part of the first author’s graduate course on “Merging Models and Data” (CEE-290) taught at the University of California, Irvine. An animated presentation of this material can be found online at https://www.youtube.com/watch?v=bhA9vtiHxZ0. The DREAM family of algorithms discussed in this chapter are implemented in DREAM Suite, an easy to use, plug-and-play, Windows program. This program can be found online at www.dreamsuite.eu and simplifies considerably Bayesian analysis and its application to uncertainty quantification of mathematical models.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Jasper A. Vrugt .

Editor information

Editors and Affiliations

Section Editor information

Appendix

Appendix

1.1 A: Derivation of Bayes’ Theorem

Bayes’ theorem (also referred to as Bayes’ law or Bayes’ rule) is a relatively simple but fundamental result of probability theory that allows for the calculation of certain conditional probabilities. The theorem specifies the relationship between the probability of two entities, A and D, or P(A) and P(D), and their respective conditional probabilities, P(A|D) and P(D|A). This theorem follows logically from Kolmogorovs (1903–1987) axiomatic definition of probability and is consistent with the frequentist and subjectivist approach to epistemology.

If P(A) > 0 and P(D) > 0 denote the probability of two different events A and D, then the conditional probability of A given event D is equivalent to

$$ P\left(A|D\right)=\frac{P\left(A\cap D\right)}{P(D)}, $$
(83)

where P(A ∩ D) signifies the probability of the union of events A and D. Similarly, the conditional probability of D given event A is

$$ P\left(D|A\right)=\frac{P\left(D\cap A\right)}{P(A)}. $$
(84)

Per definition, P(A ∩ D) = P(D ∩ A) which implies that

$$ P\left(A\cap D\right)=P(D)P\left(A|D\right)=P(A)P\left(D|A\right), $$
(85)

which after simple rearrangement leads to Bayes’ theorem in Eq. (11)

$$ P\left(A|D\right)=\frac{P(A)P\left(D|A\right)}{P(D)}, $$
(86)

where A signifies the parameter values, and B denotes the data.

The different probabilities in Eq. (86) may have different interpretations, depending on the intended goal of application. Within the context of statistical inference, Bayes’ theorem expresses mathematically how a subjective initial degree of belief, P(a), in a proposition a, changes rationally to P(a|d) in response to new data, d. The evidence d is not to be confused with the evidence, P(d), or marginal likelihood. The term P(a) is called the prior distribution, and P(a|d) denotes the posterior probability density function, or the degree of belief having accounted for the evidence d. This subjectivist approach is the cornerstone of Bayesian inference, yet Bayes’ theorem has much wider applicability. In our application of Bayes theorem, we can replace the conditional probability, P(d|a) with the data likelihood, L(a|d) as all our inferences are drawn from the residuals of a and d, that is a − d. Whether we center the measurement error distribution on the proposition, a (simulated data), or the “evidence,” b (observed data), this does not change the degree of belief in a.

To illustrate the application of Bayes theorem, let us consider a simple thought experiment in which we are trying to infer the probability that someone has a disease, X, given that they have some symptom, S. That the person has this symptom is clearly visible to the eye, but whether they have the decease is not evident. Bayes’ law tells us that P(X|S) can be derived from

$$ P\left(X|S\right)=\frac{P(X)P\left(S|X\right)}{P(S)}. $$
(86)

So to compute P(X|S), we need to know the prior probability, P(S) and P(X), of the symptom and the disease, respectively (how common are the symptom and disease), and P(S|X), the probability that someone has symptom S given that he/she has the disease, X (via lab tests).

We can confirm Bayes’ law with a simple practical example (see Fig. 23) wherein the occurrence of two, presumably correlated, events, Rain and Thunder, is observed at some place on our planet for a period of n = 20-days. The prior probabilities of both events, P(R) and P(T), and their respective conditional probabilities, P(R|T) and P(T|R), are easy to calculate from the data.

Fig. 23
figure 23

A simple data set of two discrete events, Rain and Thunder. A value of one (zero) on a given day means that the event has (not) been observed. The data can be used to calculate the prior probabilities of R and T, and their conditional probabilities, P(R|T) and P(T|R). These conditional probabilities can be confirmed with Bayes’ law

We can now use these (conditional) probabilities to benchmark Bayes’ law. Indeed, per Bayes’ theorem, P(R|T) = P(R)P(T|R)/P(T), which gives P(R|T) = (11/20 × 4/11)/(5/20) = (4/20)/(5/20) = 4/5. This confirms the value of P(R|T) = 4/5 computed directly from the data. The same result is found for P(T|R).

1.2 B: MATLAB Code DREAM

The core of the DREAM algorithm can be written in MATLAB in about 30 lines of code (see below). Based on input arguments, prior (function handle that draws samples from prior distribution), f (function handle that returns target density), N (number of chains), M (desired number of iterations), d (number of parameters) and problem (structure that allows user to pass additional input arguments to f or prior), the DREAM function returns as output to the user the multidimensional array x which stores the sampled states and corresponding target densities of each chain (third dimension). Example function handles for some d-variate uniform prior distribution, prior = @(N,d) unifrnd(−10,10,N,d), and standard normal target distribution, f = @(x,d) mvnpdf(x,zeros(1,d),eye(d)).

figure d

The variables in the DREAM function are chosen carefully to match, insofar possible, their symbols used in the main text. Built-in functions are highlighted with a low dash and information about their respective input and output arguments is provided by the MATLAB “help” utility. The jump vector, dx(j,1:d), of the jth chain contains the desired information about the scale and orientation of the proposal distribution and is derived from the remaining N-1 chains. The function check() is used as a patch for outlier chains, a critical vulnerability of multi-chain MCMC methods such as SCEM-UA, DE-MC, and DREAM (Vrugt et al. 2003; ter Braak and Vrugt 2008; Vrugt et al. 2008, 2009). Note, vectorization of the inner (proposal) loop would enhance significantly computational efficiency, yet affects negatively readability.

The MATLAB code of DREAM presented in this Appendix has several important restrictions (e.g., uniform prior, fixed crossover selection probabilities, convergence is not monitored, lack of built-in likelihood functions) – all of which are addressed in the MATLAB toolbox of DREAM developed by Vrugt (2016). This toolbox also allows the user to evaluate the chains in parallel using the distributed computing toolbox of MATLAB (see Vrugt (2016) for a multicore DREAM implementation). This parallel implementation violates detailed balance of the sampled chain trajectories, nonetheless, benchmark experiments on a diverse set of problems have shown that this violation hardly affects the results.

1.3 C: MATLAB Code DREAM(LOA)

Basic MATLAB implementation of the DREAM(LOA) algorithm for limits of acceptability sampling. This code is identical to DREAM in Appendix B except for lines 29–31 which accommodate the revised acceptance rule of Eq. (80). Input argument f is an anonymous function handle that returns the value of the fitness in Eq. (81), and the structure problem allows the user to pass to f the observed data and corresponding limits of acceptability.

figure e

The variables in the DREAM(LOA) function are chosen carefully to match, insofar possible, their symbols used in the main text. Built-in functions are highlighted with a low dash. Detailed documentation on each of these functions can be found in the MATLAB “help” system.

The fitness has to be defined as an anonymous function handle as follows, f = @(x,problem) fitness(x,problem), wherein problem is a structure with fields Yobs and Delta that store in a n-vector the measurements and limits of acceptability, respectively. A template fitness function, f, is given below.

figure f

The fitness function includes a call to own_model_script, which executes the forward model and returns simulated values for a given d-vector of parameter values, x. This function should be written by the user.

Rights and permissions

Reprints and permissions

Copyright information

© 2019 Springer-Verlag GmbH Germany, part of Springer Nature

About this entry

Check for updates. Verify currency and authenticity via CrossMark

Cite this entry

Vrugt, J.A., Massoud, E.C. (2019). Uncertainty Quantification of Complex System Models: Bayesian Analysis. In: Duan, Q., Pappenberger, F., Wood, A., Cloke, H., Schaake, J. (eds) Handbook of Hydrometeorological Ensemble Forecasting. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-39925-1_27

Download citation

Publish with us

Policies and ethics