---
title: "Introduction - Bayesian Statistics"
canonical: "https://modelassist.epixanalytics.com/space/EA/26575368/Introduction%20-%20Bayesian%20Statistics"
format: markdown
---
# Bayesian inference

  


<span style="color: #000000">Bayesian inference models the process of learning. That is, we start with a certain level of belief, however vague, and through the accumulation of experience, our belief becomes more fine-tuned. Some people take a dislike to Bayesian inference because it is overtly subjective and they like to think of statistics as being objective. We don't agree, because any statistical analysis is necessarily subjective as a result of the need to make assumptions, but also because many approximations are accepted without question, even without warning that they have been made. For that reason we appreciate the extra transparency of Bayesian inference, but it also frequently provides answers where classical statistics cannot. Perhaps more importantly for us as risk analysts, Bayesian inference encourages our clients to think about the level of knowledge </span><span style="color: #000000">*they*</span><span style="color: #000000"> have about their problem, and what that means to them.</span>

  


Bayesian inference is an extremely powerful technique, based on [Bayes' Theorem](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26574955/) (sometimes called  Bayes' Formula), for using data to improve one's estimate of a parameter. There are essentially three steps involved:

  


1. Constructing a confidence distribution of the parameter before analyzing the new data set. This is called the prior distribution;
2. Find an appropriate [likelihood function](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575381/) for the observed data; and
3. Modify the prior distribution using the likelihood function to get a revised estimate known as the posterior distribution.

> Macro (gliffy)

 

| **1** | **2** | **3** |
| --- | --- | --- |
| [Introduction - Prior Distributions](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575371) | [Introduction - Prior Distributions](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575371) | [Introduction - Prior Distributions](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575371) |
|  | [Modeling Correlations](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575455) | [Modeling Correlations](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575455) |
| [Markov chain Monte Carlo (MCMC) simulation](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575386) | [Markov chain Monte Carlo (MCMC) simulation](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575386) | [Markov chain Monte Carlo (MCMC) simulation](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575386) |
| [Approximate Bayesian Computation (ABC) rejection algorithm](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575384/Approximate+Bayesian+Computation+ABC+rejection+algorithm) | [Approximate Bayesian Computation (ABC) rejection algorithm](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575384/Approximate+Bayesian+Computation+ABC+rejection+algorithm) | [Approximate Bayesian Computation (ABC) rejection algorithm](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575384/Approximate+Bayesian+Computation+ABC+rejection+algorithm) |
| [Constructing a Bayesian inference posterior distribution in Excel](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575383) | [Constructing a Bayesian inference posterior distribution in Excel](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575383) |  |
| [Conjugate priors](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575373) |  |  |


<span style="color: #000000">This section starts with some introductory topics:</span>

  


[Introduction to the concept and some simple examples](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575369/)

[How to determine prior distributions](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575371)

[How to determine likelihood functions](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575381/)

  


<span style="color: #000000">We then turn to the actual execution of a Bayesian inference for risk analysis models with Crystal Ball by looking at various techniques for arriving at the posterior distribution:</span>

  


[Construction method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575383/)

[Conjugate prior method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575373/)

[Simulation with accept/reject method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575384/Approximate+Bayesian+Computation+ABC+rejection+algorithm)

[Markov Chain Monte Carlo method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575386/)

  


<span style="color: #000000">Most important of all, we offer a number of worked examples:</span>

  


**Examples of Bayesian inference calculations**

 

<span style="color: #000000">***General estimation problems***</span>

[Identifying a weighted coin](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575395/Bayesian+analysis+example+Identifying+a+weighted+coin)

A simple Bayesian inference example using [construction](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575383/)

[Tigers in the jungle](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575396/)

<span style="color: #000000">Simple construction model showing the interaction between likelihood functions and informed priors</span>

[Gender of a random sample of people](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575399/Bayesian+analysis+example+The+Monty+Hall+problem)

<span style="color: #000000">A simple construction model illustrating the importance of the prior distribution</span>

[Micro-fractures on turbine blades](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575398/)

A model to show how to incorporate hyperparameters by simulation, as well as offering both simulation and construction approaches to determining the posterior distribution

[The Monty Hall problem](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575399/Bayesian+analysis+example+The+Monty+Hall+problem)

<span style="color: #000000">A fun model of a classic problem showing the sometimes non-intuitive nature of the Bayesian result</span>

[Using cow pats to estimate infected animals in a herd](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575400/)

<span style="color: #000000">A bit gross, but this example shows how you can perform Bayesian inference calculations with very involved stochastic processes (i.e. very complicated likelihood functions) by using Monte Carol simulation with accept/reject criteria.</span>

[Bayesian estimation of a components mean time to failure MTTF](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575401/)

<span style="color: #000000">A simple construction example that shows how we use data that describe being above or below a threshold, instead of exact observations</span>

  


***[Taylor](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575387/)***[ ](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575387/)***[series approximation to a Bayesian posterior distribution](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575387/)***

<span style="color: #000000">Showing how Taylor series expansion lets you determine the normal approximation to posterior distributions, and a method for algebraically obtaining the standard deviation</span>

[Normal approximation to the Beta posterior distribution](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575394)

<span style="color: #000000">Example of a Taylor series expansion</span>

  


***Two common statistical problems***

[Estimate of the mean of a Normal distribution with unknown standard deviation](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575390/)

A standard statistics problem with the same outcome as the [classical method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575345/)

  


[Bayesian estimate of the mean of a Normal distribution with known standard deviation](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575391/)

Another standard statistics problem with the same outcome as the [classical method](https://epixanalytics.atlassian.net/wiki/spaces/EA/pages/26575344/)

  


<span style="color: #ffffff">Once you have reviewed the material in this section, you might like to test how much you have learned by taking the self-test quiz:</span>

  


<span style="color: #ffffff">A quiz on Bayesian inference: </span>> Macro (take-quiz-button)



  


  


  


---