Skip to content

Commit 37c33f3

Browse files
committed
integrated new content
Definition and Proof by @tomfaulkenberry were integrated: - "/D/em" renamed to "/D/enc" - did cosmetic corrections on "/P/bf-sddr" and "/P/bf-ep" - "/D/encm" and "/P/bf-ep" added to "/I/Table_of_Contents" - added source to "/P/bf-sddr"
1 parent fb45bf6 commit 37c33f3

5 files changed

Lines changed: 43 additions & 36 deletions

File tree

D/bf.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ $$ \label{eq:BF}
3434
\text{BF}_{12} = \frac{p(y\mid m_1)}{p(y\mid m_2)}.
3535
$$
3636

37-
Note: by [Bayes Theorem](/P/bayes-th), the ratio of [posterior model probabilities](/D/pmp) (i.e., the posterior model odds) can be written as
37+
Note that by [Bayes' theorem](/P/bayes-th), the ratio of [posterior model probabilities](/D/pmp) (i.e., the posterior model odds) can be written as
3838

3939
$$ \label{eq:odds}
4040
\frac{p(m_1 \mid y)}{p(m_2 \mid y)} = \frac{p(m_1)}{p(m_2)} \cdot \frac{p(y\mid m_1)}{p(y\mid m_2)},
@@ -46,4 +46,4 @@ $$ \label{eq:odds2}
4646
\frac{p(m_1 \mid y)}{p(m_2 \mid y)} = \frac{p(m_1)}{p(m_2)} \cdot \text{BF}_{12}.
4747
$$
4848

49-
In other words, the Bayes factor can be viewed as the factor by which the prior model odds are updated (after observing data $y$) to posterior model odds (see also [Bayes' rule](/P/bayes-rule)).
49+
In other words, the Bayes factor can be viewed as the factor by which the prior model odds are updated (after observing data $y$) to posterior model odds – which is also expressed by [Bayes' rule](/P/bayes-rule).

D/em.md renamed to D/encm.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ sources:
1818
year: 2005
1919
title: "Bayesian model selection using encompassing priors"
2020
in: "Statistica Neerlandica"
21-
pages: "vol. 59, no. 1., pp. 57-69"
21+
pages: "vol. 59, no. 1, pp. 57-69"
2222
url: "https://dx.doi.org/10.1111/j.1467-9574.2005.00279.x"
2323
doi: "10.1111/j.1467-9574.2005.00279.x"
2424

2525
def_id: "D93"
26-
shortcut: "em"
26+
shortcut: "encm"
2727
username: "tomfaulkenberry"
2828
---
2929

3030

31-
**Definition:** Consider a family $f$ of [generative models](/D/gm) $m$ on data $y$, where each $m \in f$ is defined by placing an inequality constraint on model parameter(s) $\theta$ (e.g., $m:\theta>0$. Then the encompassing model $m_e$ is constructed such that each $m$ is nested within $m_e$ and all inequality constraints on the parameter(s) $\theta$ are removed.
31+
**Definition:** Consider a family $f$ of [generative models](/D/gm) $m$ on data $y$, where each $m \in f$ is defined by placing an inequality constraint on model parameter(s) $\theta$ (e.g., $m:\theta>0$). Then the encompassing model $m_e$ is constructed such that each $m$ is nested within $m_e$ and all inequality constraints on the parameter(s) $\theta$ are removed.

I/Table_of_Contents.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,9 @@ Proofs by **[Number](/I/Proof_by_Number)** and **[Topic](/I/Proof_by_Topic)**
414414

415415
3.3. Bayes factor <br>
416416
&emsp;&ensp; 3.3.1. *[Definition](/D/bf)* <br>
417-
&emsp;&ensp; 3.3.2. **[Computation using Savage-Dickey Density Ratio](/P/bf-sddr)** <br>
417+
&emsp;&ensp; 3.3.2. *[Encompassing model](/D/encm)* <br>
418+
&emsp;&ensp; 3.3.3. **[Computation using Savage-Dickey Density Ratio](/P/bf-sddr)** <br>
419+
&emsp;&ensp; 3.3.4. **[Computation using Encompassing Prior Method](/P/bf-ep)** <br>
418420

419421
3.4. Log Bayes factor <br>
420422
&emsp;&ensp; 3.4.1. *[Definition](/D/lbf)* <br>

P/bf-ep.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ sources:
2121
pages: "vol. 59, no. 1., pp. 57-69"
2222
url: "https://dx.doi.org/10.1111/j.1467-9574.2005.00279.x"
2323
doi: "10.1111/j.1467-9574.2005.00279.x"
24-
2524
- authors: "Faulkenberry, Thomas J."
2625
year: 2019
2726
title: "A tutorial on generalizing the default Bayesian t-test via posterior sampling and encompassing priors"
@@ -36,32 +35,33 @@ username: "tomfaulkenberry"
3635
---
3736

3837

39-
**Theorem:** Consider two models $m_1$ and $m_e$, where $m_1$ is nested within an [encompassing model](/D/em) $m_e$ via an inequality constraint on some parameter $\theta$, and $\theta$ is unconstrained under $m_e$. Then
40-
\[
41-
B_{1e} = \frac{c}{d} = \frac{1/d}{1/c}
42-
\]
38+
**Theorem:** Consider two models $m_1$ and $m_e$, where $m_1$ is nested within an [encompassing model](/D/encm) $m_e$ via an inequality constraint on some parameter $\theta$, and $\theta$ is unconstrained under $m_e$. Then, the [Bayes factor](/D/bf) is
39+
40+
$$ \label{eq:bf-ep}
41+
\text{BF}_{1e} = \frac{c}{d} = \frac{1/d}{1/c}
42+
$$
43+
4344
where $1/d$ and $1/c$ represent the proportions of the posterior and prior of the encompassing model, respectively, that are in agreement with the inequality constraint imposed by the nested model $m_1$.
4445

45-
**Proof:**
46-
Consider first that for any model $m_1$ on data $y$ with parameter $\theta$, [Bayes theorem](/P/bayes-th) implies
46+
**Proof:** Consider first that for any model $m_1$ on data $y$ with parameter $\theta$, [Bayes' theorem](/P/bayes-th) implies
4747

4848
$$ \label{eq:bayesth}
4949
p(\theta \mid y,m_1) = \frac{p(y \mid \theta,m_1) \cdot p(\theta \mid m_1)}{p(y \mid m_1)}.
5050
$$
5151

52-
Rearranging Equation \eqref{eq:bayesth} allows us to write the [marginal likelihood](/D/ml) for $y$ under $m_1$ as
52+
Rearranging equation \eqref{eq:bayesth} allows us to write the [marginal likelihood](/D/ml) for $y$ under $m_1$ as
5353

5454
$$ \label{eq:marginal}
5555
p(y \mid m_1) = \frac{p(y \mid \theta,m_1) \cdot p(\theta \mid m_1)}{p(\theta \mid y,m_1)}.
5656
$$
5757

58-
Taking the ratio of the marginal likelihoods for $m_1$ and the [encompassing model](/D/em) $m_e$ yields the following [Bayes factor](/D/bf):
58+
Taking the ratio of the marginal likelihoods for $m_1$ and the [encompassing model](/D/encm) $m_e$ yields the following [Bayes factor](/D/bf):
5959

6060
$$ \label{eq:bayesfactor}
61-
B_{1e} = \frac{p(y \mid \theta,m_1) \cdot p(\theta \mid m_1) / p(\theta \mid y,m_1)}{p(y \mid \theta,m_e) \cdot p(\theta \mid m_e) / p(\theta \mid y,m_e)}.
61+
\text{BF}_{1e} = \frac{p(y \mid \theta,m_1) \cdot p(\theta \mid m_1) / p(\theta \mid y,m_1)}{p(y \mid \theta,m_e) \cdot p(\theta \mid m_e) / p(\theta \mid y,m_e)}.
6262
$$
6363

64-
Now, both the constrained model $m_1$ and the [encompassing model](/D/em) $m_e$ contain the same parameter vector $\theta$. Choose a specific value of $\theta$, say $\theta'$, that exists in the support of both models $m_1$ and $m_e$ (we can do this because $m_1$ is nested within $m_e$). Then, for this parameter value $\theta'$, we have $p(y \mid \theta',m_1)=p(y \mid \theta',m_e)$, so the expression for the Bayes factor (Equation \eqref{eq:bayesfactor} above) reduces to an expression involving only the priors and posteriors for $\theta'$ under $m_1$ and $m_e$:
64+
Now, both the constrained model $m_1$ and the [encompassing model](/D/encm) $m_e$ contain the same parameter vector $\theta$. Choose a specific value of $\theta$, say $\theta'$, that exists in the support of both models $m_1$ and $m_e$ (we can do this, because $m_1$ is nested within $m_e$). Then, for this parameter value $\theta'$, we have $p(y \mid \theta',m_1)=p(y \mid \theta',m_e)$, so the expression for the Bayes factor in equation \eqref{eq:bayesfactor} reduces to an expression involving only the priors and posteriors for $\theta'$ under $m_1$ and $m_e$:
6565

6666
$$ \label{eq:bayesfactor2}
6767
B_{1e} = \frac{p(\theta' \mid m_1) / p(\theta' \mid y,m_1)}{p(\theta' \mid m_e) / p(\theta' \mid y,m_e)}.
@@ -71,8 +71,8 @@ Because $m_1$ is nested within $m_e$ via an inequality constraint, the prior $p(
7171

7272
$$ \label{eq:normalize}
7373
\begin{split}
74-
p(\theta' \mid m_1) & = \frac{p(\theta' \mid m_e) \cdot I_{\theta' \in m_1}}{\int p(\theta' \mid m_e) \cdot I_{\theta' \in m_1}d\theta'}\\
75-
& = \Biggl(\frac{I_{\theta' \in m_1}}{\int p(\theta' \mid m_e) \cdot I_{\theta' \in m_1}d\theta'}\Biggr) \cdot p(\theta' \mid m_e),
74+
p(\theta' \mid m_1) & = \frac{p(\theta' \mid m_e) \cdot I_{\theta' \in m_1}}{\int p(\theta' \mid m_e) \cdot I_{\theta' \in m_1} \, \mathrm{d}\theta'}\\
75+
& = \Biggl(\frac{I_{\theta' \in m_1}}{\int p(\theta' \mid m_e) \cdot I_{\theta' \in m_1} \, \mathrm{d}\theta'}\Biggr) \cdot p(\theta' \mid m_e),
7676
\end{split}
7777
$$
7878

@@ -85,13 +85,13 @@ $$
8585
By similar reasoning, we can write the posterior as
8686

8787
$$ \label{eq:posterior}
88-
p(\theta' \mid y,m_1) = \Biggl(\frac{I_{\theta' \in m_1}}{\int p(\theta' \mid y,m_e)I_{\theta' \in m_1}d\theta'}\Biggr)\cdot p(\theta' \mid y,m_e) = d \cdot p(\theta' \mid y,m_e).
88+
p(\theta' \mid y,m_1) = \Biggl(\frac{I_{\theta' \in m_1}}{\int p(\theta' \mid y,m_e) \cdot I_{\theta' \in m_1} \, \mathrm{d}\theta'}\Biggr)\cdot p(\theta' \mid y,m_e) = d \cdot p(\theta' \mid y,m_e).
8989
$$
9090

91-
This gives us
91+
Plugging \eqref{eq:prior} and \eqref{eq:posterior} into \eqref{eq:bayesfactor2}, this gives us
9292

9393
$$ \label{eq:bayesfactor3}
9494
B_{1e} = \frac{c \cdot p(\theta' \mid m_e) / d \cdot p(\theta' \mid y,m_e)}{p(\theta' \mid m_e) / p(\theta' \mid y,m_e)} = \frac{c}{d} = \frac{1/d}{1/c},
9595
$$
9696

97-
which completes the proof. Note that by definition, $1/d$ represents the proportion of the posterior distribution for $\theta$ under the [encompassing model](/D/em) $m_e$ that agrees with the constraints imposed by $m_1$. Similarly, $1/c$ represents the proportion of the prior distribution for $\theta$ under the [encompassing model](/D/em) $m_e$ that agrees with the constraints imposed by $m_1$.
97+
which completes the proof. Note that by definition, $1/d$ represents the proportion of the posterior distribution for $\theta$ under the [encompassing model](/D/encm) $m_e$ that agrees with the constraints imposed by $m_1$. Similarly, $1/c$ represents the proportion of the prior distribution for $\theta$ under the [encompassing model](/D/encm) $m_e$ that agrees with the constraints imposed by $m_1$.

P/bf-sddr.md

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,13 @@ sources:
2121
pages: "vol. 26, no. 2, pp. 217-238"
2222
url: "https://dx.doi.org/10.29220/CSAM.2019.26.2.217"
2323
doi: "10.29220/CSAM.2019.26.2.217"
24+
- authors: "Penny, W.D. and Ridgway, G.R."
25+
year: 2013
26+
title: "Efficient Posterior Probability Mapping Using Savage-Dickey Ratios"
27+
in: "PLoS ONE"
28+
pages: "vol. 8, iss. 3, art. e59655, eq. 16"
29+
url: "https://journals.plos.org/plosone/article?id=10.1371/journal.pone.0059655"
30+
doi: "10.1371/journal.pone.0059655"
2431

2532
proof_id: "P156"
2633
shortcut: "bf-sddr"
@@ -34,39 +41,37 @@ $$ \label{eq:sd}
3441
\text{BF}_{01} = \frac{p(\delta=\delta_0\mid y,m_1)}{p(\delta=\delta_0\mid m_1)}.
3542
$$
3643

37-
**Proof:**
38-
39-
By [definition](/D/bf), the Bayes factor $\text{BF}_{01}$ is the ratio of marginal likelihoods of data $y$ over $m_0$ and $m_1$, respectively. That is,
44+
**Proof:** By [definition](/D/bf), the Bayes factor $\text{BF}_{01}$ is the ratio of marginal likelihoods of data $y$ over $m_0$ and $m_1$, respectively. That is,
4045

4146
$$ \label{eq:bf}
4247
\text{BF}_{01}=\frac{p(y \mid m_0)}{p(y \mid m_1)}.
4348
$$
4449

45-
The key idea in the proof is that we can use a "change of variables" technique to express $\text{BF}_{01}$ entirely in terms of the "encompassing" model $m_1$. This proceeds by first unpacking the [marginal likelihood](/D/ml) for $m_0$ over the nuisance parameter $\varphi$ and then using the fact that $m_0$ is a sharp hypothesis nested within $m_1$ to rewrite everything in terms of $\mathcal{H}_1$. Specifically,
50+
The key idea in the proof is that we can use a "change of variables" technique to express $\text{BF}_{01}$ entirely in terms of the "encompassing" model $m_1$. This proceeds by first unpacking the [marginal likelihood](/D/ml) for $m_0$ over the nuisance parameter $\varphi$ and then using the fact that $m_0$ is a sharp hypothesis nested within $m_1$ to rewrite everything in terms of $m_1$. Specifically,
4651

47-
$$
52+
$$ \label{eq:ml-m0}
4853
\begin{split}
49-
p(y \mid m_0) &= \int p(y \mid \varphi,m_0)p(\varphi\mid m_0)d\varphi\\
50-
&= \int p(y \mid \varphi,\delta=\delta_0,m_1)p(\varphi\mid \delta=\delta_0,m_1)d\varphi\\
54+
p(y \mid m_0) &= \int p(y \mid \varphi,m_0) \, p(\varphi\mid m_0) \, \mathrm{d} \varphi \\
55+
&= \int p(y \mid \varphi,\delta=\delta_0,m_1) \, p(\varphi\mid \delta=\delta_0,m_1) \, \mathrm{d} \varphi \\
5156
&= p(y \mid \delta=\delta_0,m_1).\\
5257
\end{split}
5358
$$
5459

55-
By [Bayes Theorem](/P/bayes-th), we can rewrite this last line as
60+
By [Bayes' theorem](/P/bayes-th), we can rewrite this last line as
5661

57-
$$
58-
p(y \mid \delta=\delta_0,m_1) = \frac{p(\delta=\delta_0\mid y,m_1)p(y \mid m_1)}{p(\delta=\delta_0\mid m_1)}.
62+
$$ \label{eq:ml-m0-bt}
63+
p(y \mid \delta=\delta_0,m_1) = \frac{p(\delta=\delta_0\mid y,m_1) \, p(y \mid m_1)}{p(\delta=\delta_0\mid m_1)}.
5964
$$
6065

6166
Thus we have
6267

6368
$$
6469
\begin{split}
65-
\text{BF}_{01} &= \frac{p(y \mid m_0)}{p(y \mid m_1)}\\
70+
\text{BF}_{01} &\overset{\eqref{eq:bf}}{=} \frac{p(y \mid m_0)}{p(y \mid m_1)}\\
6671
&= p(y \mid m_0) \cdot \frac{1}{p(y \mid m_1)}\\
67-
&= p(y \mid \delta=\delta_0,m_1) \cdot \frac{1}{p(y \mid m_1)}\\
68-
&= \frac{p(\delta=\delta_0\mid y,m_1)p(y \mid m_1)}{p(\delta=\delta_0\mid m_1)} \cdot \frac{1}{p(y \mid m_1)}\\
69-
&=\frac{p(\delta=\delta_0 \mid y,m_1)}{p(\delta=\delta_0\mid m_1)},
72+
&\overset{\eqref{eq:ml-m0}}{=} p(y \mid \delta=\delta_0,m_1) \cdot \frac{1}{p(y \mid m_1)}\\
73+
&\overset{\eqref{eq:ml-m0-bt}}{=} \frac{p(\delta=\delta_0\mid y,m_1) \, p(y \mid m_1)}{p(\delta=\delta_0\mid m_1)} \cdot \frac{1}{p(y \mid m_1)}\\
74+
&= \frac{p(\delta=\delta_0 \mid y,m_1)}{p(\delta=\delta_0\mid m_1)},
7075
\end{split}
7176
$$
7277

0 commit comments

Comments
 (0)