Skip to content

Commit 6ddc932

Browse files
authored
added proof "bin-map"
1 parent 8fddac3 commit 6ddc932

1 file changed

Lines changed: 72 additions & 0 deletions

File tree

P/bin-map.md

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
---
2+
layout: proof
3+
mathjax: true
4+
5+
author: "Joram Soch"
6+
affiliation: "BCCN Berlin"
7+
e_mail: "joram.soch@bccn-berlin.de"
8+
date: 2023-12-01 14:36:54
9+
10+
title: "Maximum-a-posteriori estimation for binomial observations"
11+
chapter: "Statistical Models"
12+
section: "Count data"
13+
topic: "Binomial observations"
14+
theorem: "Maximum-a-posteriori estimation"
15+
16+
sources:
17+
18+
proof_id: "P427"
19+
shortcut: "bin-map"
20+
username: "JoramSoch"
21+
---
22+
23+
24+
**Theorem:** Let $y$ be the number of successes resulting from $n$ independent trials with unknown success probability $p$, such that $y$ follows a [binomial distribution](/D/bin):
25+
26+
$$ \label{eq:Bin}
27+
y \sim \mathrm{Bin}(n,p) \; .
28+
$$
29+
30+
Moreover, assume a [beta prior distribution](/P/bin-prior) over the model parameter $p$:
31+
32+
$$ \label{eq:Bin-prior}
33+
\mathrm{p}(p) = \mathrm{Bet}(p; \alpha_0, \beta_0) \; .
34+
$$
35+
36+
Then, the [maximum-a-posteriori estimate](/D/map) of $p$ is
37+
38+
$$ \label{eq:Bin-MLE}
39+
\hat{p}_\mathrm{MAP} = \frac{\alpha_0+y-1}{\alpha_0+\beta_0+n-2} \; .
40+
$$
41+
42+
43+
**Proof:** Given the [prior distribution](/D/prior) in \eqref{eq:Bin-prior}, the [posterior distribution](/D/post) for [binomial observations](/D/bin-data) [is also a beta distribution](/P/bin-post)
44+
45+
$$ \label{eq:Bin-post}
46+
\mathrm{p}(p|y) = \mathrm{Bet}(p; \alpha_n, \beta_n)
47+
$$
48+
49+
where the [posterior hyperparameters](/D/post) are equal to
50+
51+
$$ \label{eq:Bin-post-par}
52+
\begin{split}
53+
\alpha_n &= \alpha_0 + y \\
54+
\beta_n &= \beta_0 + (n-y) \; .
55+
\end{split}
56+
$$
57+
58+
The [mode of the beta distribution](/P/beta-mode) is given by:
59+
60+
$$ \label{eq:beta-mode}
61+
X \sim \mathrm{Bet}(\alpha, \beta) \quad \Rightarrow \quad \mathrm{mode}(X) = \frac{\alpha-1}{\alpha+\beta-2} \; .
62+
$$
63+
64+
Applying \eqref{eq:beta-mode} to \eqref{eq:Bin-post} with \eqref{eq:Bin-post-par}, the [maximum-a-posteriori estimate](/D/map) of $p$ follows as:
65+
66+
$$ \label{eq:Bin-MAP}
67+
\begin{split}
68+
\hat{p}_\mathrm{MAP} &= \frac{\alpha_n-1}{\alpha_n+\beta_n-2} \\
69+
&\overset{\eqref{eq:Bin-post-par}}{=} \frac{\alpha_0+y-1}{\alpha_0+y+\beta_0+(n-y)-2} \\
70+
&= \frac{\alpha_0+y-1}{\alpha_0+\beta_0+n-2} \; .
71+
\end{split}
72+
$$

0 commit comments

Comments
 (0)