0% found this document useful (0 votes)
66 views34 pages

BA3202-L1 Bayesian

This document provides an overview of an actuarial statistics course taught by Wenjun Zhu at Nanyang Technological University. It outlines the course materials, assessment components including coursework, presentations, quizzes and a final exam. It also describes the expectations of students to engage with the course material and the instructor's commitment to being available for support.

Uploaded by

Hagan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
66 views34 pages

BA3202-L1 Bayesian

This document provides an overview of an actuarial statistics course taught by Wenjun Zhu at Nanyang Technological University. It outlines the course materials, assessment components including coursework, presentations, quizzes and a final exam. It also describes the expectations of students to engage with the course material and the instructor's commitment to being available for support.

Uploaded by

Hagan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 34

BA3202

Actuarial Statistics
Actuarial Statistics
Course opening
Instructor:
Wenjun Zhu, PhD, FSA, CERA
Assistant Professor
Email: wjzhu@ntu.edu.sg
Office: S3-B1B-71
Tel: (65)6592-1859

Division of Banking & Finance


Nanyang Technological University

BA3202
L1
Actuarial Statistics
• All course material posting on NTULearn

• KEY READING:
• Lecture slides for each week will be uploaded on NTULearn

Wenjun Zhu wjzhu@ntu.edu.sg


• CS1 – Actuarial Statistics 1.
• CS2 – Actuarial Statistics 2.
• Additional materials:
• Practice questions problem set – basic + exam style questions
• Additional tutorial questions – exam style questions

BA3202
L1
Course assessment

Actuarial Statistics
Components Marks
Coursework: Participation) 10

Wenjun Zhu wjzhu@ntu.edu.sg


Coursework: Presentation) 10
Coursework: Mid-term quiz
10
(Likely the week after recess week)
Final examination 70

Total 100

BA3202
L1
Tutorial presentations

Actuarial Statistics
• Group presentation (10 marks)
• Timing: 30 - 45 min
• Material for presentation
• A simple case study, applying previous lecture
concepts/knowledge/methodologies/formulae into real economic/actuarial
scenarios.

Wenjun Zhu wjzhu@ntu.edu.sg


• Can be either quantitative or qualitative
• E.g., introduce a business scenario that apply the learnt knowledge
• E.g., do some simple data analytics examples
• Anything that relates the previous lecture is acceptable
• Practice question problem set
• Needs to be uploaded to NTUlearn after the presentation
• Marking scheme
• Case study & problem set (50%)
• Presentation & communication (50%)
• Mid-term quiz
• After recess week
• Coverage: week 1- week 6 5
• Same question style as the final
BA3202
L1
Expectation of you

Actuarial Statistics
• Catch up with material that’s left behind after each lecture
• Do practice questions after each lecture
• Let me know WHENEVER you have any trouble with my
teaching (speaking too fast/slow, slides or notes not clear

Wenjun Zhu wjzhu@ntu.edu.sg


enough etc.)

• HAVE FUN !!!

BA3202
L1
Expectations of me

Actuarial Statistics
• You are welcome of expressing any of your expectations of me
in terms of:
• Style of class
• Length of the seminars

Wenjun Zhu wjzhu@ntu.edu.sg


• Other questions
• Weekly office hour
• Wednesday 2:00 – 3:00 pm
• Or upon appointment
• Zoom/Teams channel
• Available upon appointment

BA3202
L1
BA3202

Actuarial Statistics
Actuarial Statistics

Lecture 1:
- Decision Theory
- Bayesian Statistics

BA3202
L1
Objectives

Actuarial Statistics
• Decision theory
1. Define the 2 player zero sum games.
2. Determine optimum strategies under the theory of games.
3. Explain what is meant by a decision function and a risk function.

Wenjun Zhu wjzhu@ntu.edu.sg


4. Apply decision criteria to determine which decision functions are
the best.
• Bayesian statistics
1. Use Bayes’ Theorem to calculate simple conditional probabilities.
2. Explain what is meant by a prior distribution, a posterior
distribution and a conjugate prior distribution.
3. Derive the posterior distribution for a parameter in simple cases.
4. Explain what is meant by a loss function.
5. Determine Bayesian estimates of parameters based on loss 9
functions.
BA3202
L1
Decision Theory

L1

Wenjun Zhu wjzhu@ntu.edu.sg Actuarial Statistics


10

BA3202
Game Theory

Actuarial Statistics
• Zero-sum two-person games
• A game is said to be zero-sum when there are two
players in conflict and whenever one player loses,
the other player wins.
• The net change in benefit/wealth is zero

Wenjun Zhu wjzhu@ntu.edu.sg


• Examples of zero-sum two player games?
• Futures, Options, etc.
• Stock trading
• Other examples?
• Assumptions
• Neither player knows what the other will do
• i.e., perfect understanding and perfect information
• Strategy cannot be changed once chosen 11

BA3202
L1
Game Theory

Actuarial Statistics
• Represent the game with Loss Matrix
• Player A’s options: I, II, III ...
• Player B’s options: 1, 2, 3 etc.
• L(I, 1), L(II, 1), L(I, 2) and L(II, 2) are the values of the loss function

Wenjun Zhu wjzhu@ntu.edu.sg


• L(I, 1) represents the loss to A (and i.e., the gain to B) when A
chooses option I and B chooses option 1
• The entries in the matrix are called payoffs of the game
• The objectives of Game Theory: Player A
• Optimal strategies I II
• Value/payoff of the game 1 L(I,1) L(II,1)
Player B
2 L(I,2) L(II,2)

12

BA3202
L1
Domination

Actuarial Statistics
• Strategy I dominates II if Player A (LOSSES)
• I is at least as good as II I II III IV
• I is better in some cases 1 2 0 < 1 4
Player B
2 1 2 < 2 3

Wenjun Zhu wjzhu@ntu.edu.sg


• A dominated strategy can (GAINS)
always be discarded. 3 4 1 < 3 2

• Strategy II dominates III


• What will happen finally? • III is redundant

• How to determine the Player A (LOSSES)


optimal strategy? I II IV
1 2 0 < 4
Player B 13
2 1 2 < 3
(GAINS)
3 4 1 < 2 BA3202
L1
The minimax criterion

Actuarial Statistics
• Each player chooses strategy that has the Player A (LOSSES)
lowest “maximum-loss” I II III
• Player A’s maximum losses:
1 6 2 2
• I: 6; II:3; III: 5 Player B
2 4 3 5
• 3 is the lowest of all (GAINS)
3 -3 1 0

Wenjun Zhu wjzhu@ntu.edu.sg


• A will choose strategy II
• Player B’s maximum losses (lowest gains)
• S1:-2; S2: -3; S3:3 (Note: negative signs since
we look at losses)
• “-3” is the lowest of all
• B will choose strategy 2
• The game now has an equilibrium point
• Saddle Points (Local minimum/maximum)
is where element L(a,b) is the
14
• largest in column and
• smallest in row
BA3202
L1
Randomized strategy

Actuarial Statistics
• Alternative strategy: minimize the “maximum expected loss”
• Example: determine the optimum strategy for Player A
• No saddle point
• 𝑝: Probability of strategy I for player A Player A

Wenjun Zhu wjzhu@ntu.edu.sg


• If player B chooses S1, A’s expected loss: I II
𝐿! 𝑝 = 7𝑝 − 6 1 − 𝑝 = 13𝑝 − 6 1 7 -6
• If player B chooses S2, A’s expected loss: Player B
2 1 5
𝐿" 𝑝 = 𝑝 + 5 1 − 𝑝 = 5 − 4𝑝
• Find 𝑝 such that max{𝐿! 𝑝 , 𝐿" (𝑝)} is minimized
10
à achieved when
𝐿! 𝑝 = 𝐿" (𝑝)
5
!!
13𝑝 − 6 = 5 − 4𝑝 ⇒ 𝑝 =
!# 0
0 0.2 0.4 0.6 0.8 1
!! !! $!
• The value of the game=𝐿! = 𝐿" = -5
!# !# !# 15
-10

L1 L2
BA3202
L1
Statistical games

Actuarial Statistics
• Purpose of all statistical inference:
• learn more about the population
• Process: study a collected sample
• 2 person game: player A is the Statistician; player B is the
Nature.

Wenjun Zhu wjzhu@ntu.edu.sg


• Unlike the zero-sum game, statistician has some indication of
how the Nature behave, given information in the sample
• She is making decisions against the potential outcome of nature
• The resulting decision matrix (a 2×2 example):
• Statistician can make decisions 𝑎! and 𝑎" Statistician
• The nature has states 𝜃! and 𝜃" 𝑎! 𝑎"
𝜃! 𝐿(𝑎! , 𝜃! ) 𝐿(𝑎" , 𝜃! )
Nature 16
𝜃" 𝐿(𝑎! , 𝜃" ) 𝐿(𝑎" , 𝜃" )
BA3202
L1
Example

Actuarial Statistics
• A coin either has 1 head or 1 tail (Normal) or 2 heads (Biased).
• The statistician cannot inspect the coin, but can make a
decision based on one single sample toss.
• 2×2 matrix of available strategy
• 𝜃! : coin is two-headed (i.e., biased, denoted as B)

Wenjun Zhu wjzhu@ntu.edu.sg


• 𝜃" : coin has 1 head and 1 tail (i.e., normal, denoted as N)
• 𝑎! : Statistician’s decision is that coin is two-headed (B)
• 𝑎" : Statistician’s decision is that coin is normal (N)
• 𝐿(𝑎! , 𝜃" ): the loss function of strategy
𝑎! with nature 𝜃" Statistician
𝑎! 𝑎"
𝜃! 𝐿(𝑎! , 𝜃! ) 𝐿(𝑎" , 𝜃! )
Nature
• 2×2 matrix of available strategy 𝜃" 𝐿(𝑎! , 𝜃" ) 𝐿(𝑎" , 𝜃" ) 17

BA3202
L1
Example (Cont’d)

Actuarial Statistics
• If the statistician makes the wrong decision, there is a penalty
of $1.
Statistician
𝑎! 𝑎"

Wenjun Zhu wjzhu@ntu.edu.sg


𝜃! 𝐿(𝑎! , 𝜃! ) 𝐿(𝑎" , 𝜃! )
Nature
𝜃" 𝐿(𝑎! , 𝜃" ) 𝐿(𝑎" , 𝜃" )

Statistician
𝑎! 𝑎"
𝜃! 0 1
Nature
𝜃" 1 0 18

BA3202
L1
Example (Cont’d)

Actuarial Statistics
0, ℎ𝑒𝑎𝑑
• Sample random variable : 𝑥 = %
1, 𝑡𝑎𝑖𝑙
• 𝑥 is what the statistician observes based on one sample toss
• 𝑑# (𝑥): decision functions based on observation of 𝑥

Wenjun Zhu wjzhu@ntu.edu.sg


• Subscript 𝑖 indicates different decision functions
• Possible decision functions are
𝑑! 0 = 𝑎! and 𝑑! 1 = 𝑎" (see a head->B; see a tail->N)
𝑑" 0 = 𝑎! and 𝑑" 1 = 𝑎! (see a head->B; see a tail->B)
𝑑% 0 = 𝑎" and 𝑑% 1 = 𝑎" (see a head->N; see a tail->N)
𝑑$ 0 = 𝑎" and 𝑑$ 1 = 𝑎! (see a head->N; see a tail->B)
• Some decision functions may not be very meaningful.

19

BA3202
L1
Example (Cont’d)

Actuarial Statistics
• 𝑅(𝑑# , 𝜃$ ): expected loss under 𝜃$ nature using decision function 𝑑#
𝑅 𝑑# , 𝜃$ = 𝐸(𝐿(𝑑# 𝑥 , 𝜃$ ))
where 𝐿(𝑑# 𝑥 , 𝜃$ ) is the loss function under decision function 𝑑# and
the nature is 𝜃$ .

Wenjun Zhu wjzhu@ntu.edu.sg


• Let’s look at 𝑅 𝑑! , 𝜃$ :
• Under 𝜃! : Pr 𝑥 = 0 = 1, Pr 𝑥 = 1 = 0
• Under 𝜃" : Pr 𝑥 = 0 = 0.5, Pr 𝑥 = 1 = 0.5
• 𝑅 𝑑! , 𝜃! = Pr 𝑥 = 0 𝐿 𝑑! 0 , 𝜃! + Pr 𝑥 = 1 𝐿 𝑑! 1 , 𝜃! = 0
• 𝑅 𝑑! , 𝜃" = Pr 𝑥 = 0 𝐿 𝑑! 0 , 𝜃" + Pr 𝑥 = 1 𝐿 𝑑! 1 , 𝜃" = 0.5

• After class try to calculate 𝑅 𝑑# , 𝜃$ for 𝑖 = 2, 3,4. Now we have:


• 𝑅 𝑑! , 𝜃! = 0;𝑅 𝑑! , 𝜃" = 0.5
• 𝑅 𝑑" , 𝜃! = 0;𝑅 𝑑" , 𝜃" =1
• 𝑅 𝑑% , 𝜃! = 1;𝑅 𝑑% , 𝜃" =0 20
• 𝑅 𝑑$ , 𝜃! = 1;𝑅 𝑑$ , 𝜃" = 0.5
BA3202
L1
Example (Cont’d)

Actuarial Statistics
• Write into an expected payoff Statistician
matrix: 𝑑! 𝑑" 𝑑% 𝑑$
• 𝑑! dominates 𝑑" 𝜃! 0 0 1 1
• 𝑑# dominates 𝑑$ Nature
𝜃" 0.5 1 0 0.5
• Reduce to a new 2×2 payoff matrix

Wenjun Zhu wjzhu@ntu.edu.sg


Statistician
𝑑! 𝑑%
• Optimal randomized strategy:
𝜃! 0 1
" Nature
• select 𝑑! with probability and 𝑑# 𝜃" 0.5 0
#
!
with probability #
• Value of game:
1
𝐸 𝑙𝑜𝑠𝑠 𝜃! = 𝐸 𝑙𝑜𝑠𝑠 𝜃" = 21
3

BA3202
L1
Example (Cont’d)

Actuarial Statistics
• Minimax Criterion
• Under the minimax criterion, the optimal strategy is 𝑑!
• Bayes criterion:
• Bayes risk: 𝐸[𝑅(𝑑, 𝜣)]

Wenjun Zhu wjzhu@ntu.edu.sg


• 𝜣 is regarded as a random variable
• Expectation is taken with respect to 𝜣
• Bayes criterion seeks to minimize Bayes risk
• Suppose Pr 𝜃! = 𝑝 , Pr 𝜃" = 1 − 𝑝
• Bayes risk for 𝑑! : 0 ∗ 𝑝 + 0.5 1 − 𝑝 = 0.5 − 0.5𝑝
• Bayes risk for 𝑑% : 1 ∗ 𝑝 + 0 ∗ 1 − 𝑝 = 𝑝
Statistician
! !
• When 𝑝 > , choose 𝑑! ; when 𝑝 < , choose 𝑑% 𝑑! 𝑑%
% %

𝜃! 0 1
Nature 22
𝜃" 0.5 0
BA3202
L1
Bayesian Statistics

L1

Wenjun Zhu wjzhu@ntu.edu.sg Actuarial Statistics


23

BA3202
Intro

Actuarial Statistics
• In classical statistics the parameter values (𝜃, or 𝛼, or 𝜆…any
notations) are considered to be fixed but unknown
• In Bayesian statistics the parameter values (𝜃, or 𝛼, or 𝜆…any
notations) are considered to be random numbers

Wenjun Zhu wjzhu@ntu.edu.sg


• Recall in probability: 𝑃 𝑋 𝑌 𝑃 𝑌 = 𝑃 𝑋 ∩ 𝑌 = 𝑃 𝑌 𝑋 𝑃(𝑋)

Bayes Theorem:
If 𝐵! , 𝐵" , … , 𝐵% constitute a partition of a sample space 𝑆 and 𝑃 𝐵# ≠
0 for 𝑖 = 1, 2, … , 𝑘, then for any event 𝐴 in 𝑆 such that 𝑃 𝐴 ≠ 0,
𝑃 𝐴 𝐵& 𝑃 𝐵&
𝑃 𝐵& 𝐴 =
𝑃 𝐴
where 𝑃 𝐴 = ∑%#'! 𝑃 𝐴 𝐵# 𝑃 𝐵# for 𝑖 = 1, 2, … , 𝑘.
24
• We use this theorem to find 𝑃 𝐵 𝐴 if we know 𝑃(𝐴|𝐵)
BA3202
L1
Bayes Theorem

Actuarial Statistics
Example:
3 manufacturers supply clothing to a retailer.
• 60% stock comes from manufacturer 1, 30% from manufacturer 2
and 10% from manufacturer 3.
• 10% of the clothing from manufacturer 1 is faulty, 5% from

Wenjun Zhu wjzhu@ntu.edu.sg


manufacturer 2 is faulty and 15% from manufacturer 3 is faulty.
• What is the probability that a faulty garment comes from
manufacturer 3?

Solution:
• Let 𝐴 be the event that a garment is faulty. Let 𝐵# be the event that
the garment comes from manufacturer 𝑖.
) *! ∩, ) ,|*! ) *!
• 𝑃 𝐵( 𝐴 = = =
) , ) ,|*" ) *" .) ,|*# ) *# .) ,|*! ) *!
/.!1∗/.!
= 0.167 25
/.!∗/.3././1∗/.(./.!1∗/.!

BA3202
L1
Prior/Posterior distributions

Actuarial Statistics
Suppose we have a random variable 𝑋 with known pdf 𝑓(𝑥|𝜃)
• Study target: 𝜃, unknown parameter that needs to be estimated
• Prior distribution of 𝜃: assume 𝜃 is known to have a pdf of 𝑓 𝜃
• The prior distribution comes from some other information known
about 𝜃 before drawing any sample from the population
• In the previous clothing example, the proportion of different

Wenjun Zhu wjzhu@ntu.edu.sg


manufacturers can be viewed as priors
• 𝑋 = (𝑋! , 𝑋" , … , 𝑋4 ) is a random sample from 𝑋 (population)
𝒇 𝑿𝜽 𝒇𝜽
• Posterior pdf of 𝜽: 𝒇 𝜽 𝑿 = ∝𝒇 𝑿𝜽 𝒇 𝜽
𝒇 𝑿
• With the sample 𝑋, we have more information about 𝜃 and therefore
obtained the posterior distribution
• 𝑓 𝑋 𝜃 = ∏'%&! 𝑓(𝑋% |𝜃): the likelihood of the sample is a function of
unknown 𝜃
• 𝑓 𝑋 = ∫ 𝑓 𝑋 𝜃 𝑓 𝜃 𝑑𝜃 : a constant that does not involve 𝜃
• Posterior is proportional to the likelihood function times the prior. 26

BA3202
L1
Example

Actuarial Statistics
If 𝑋~𝐸𝑥𝑝 𝜆 where 𝜆 is the unknown parameter that needs to be
estimated, and 𝑥! , 𝑥" , … , 𝑥4 is a random sample from 𝑋. Suppose
the prior distribution of 𝜆 is 𝐸𝑥𝑝 𝛼 , where 𝛼 is a known parameter.
Find the posterior distribution 𝑓 𝜆 𝑥 of 𝜆.
Solution:
• 𝑓 𝜆 = 𝛼𝑒 89: is the prior pdf of 𝜆

Wenjun Zhu wjzhu@ntu.edu.sg


• 𝑓 𝑥 𝜆 = 𝜆𝑒 8:; is the conditional pdf of 𝑋
• The likelihood function given 𝑥! , 𝑥" , … , 𝑥4 is
4
∑&
𝑓 𝑥𝜆 = N 𝜆𝑒 8:;$ = 4
𝜆 𝑒 8: $%" ;$

#'!
∑&
• Hence, 𝑓 𝜆 𝑥 ∝ 𝑓 𝑥 𝜆 𝑓 𝜆 = 𝛼𝜆4 𝑒 8 $%" ;$ .9 :

• Note: 𝛼, 𝑥! , 𝑥" , … , 𝑥' are known; 𝜆 is the only unknown variable


(!
• Recall: Gamma distribution Γ 𝑎, 𝑏 has a pdf: 𝑓 𝑥 = 𝑥 *+! 𝑒 +(,
) *
• Posterior distribution of 𝜆 is Γ 𝑛 + 1, ∑'%&! 𝑥% + 𝛼 27

BA3202
L1
Prior/Posterior distributions

Actuarial Statistics
• Step 1:
• Write down prior pdf of the unknown parameter 𝜃: 𝑓 𝜃
• Write down the conditional pdf of 𝑋: 𝑓 𝑥 𝜃 (i.e., the likelihood)
• Step 2:

Wenjun Zhu wjzhu@ntu.edu.sg


Write down the likelihood function 𝑓 𝑥 𝜃 given the random
sample {𝑥! , 𝑥" , … , 𝑥4 }
• Step 3:
Write down posterior pdf 𝑓 𝜃 𝑥 ∝ 𝑓 𝑥 𝜃 𝑓(𝜃)
• Step 4:
Identify the form of the posterior pdf that may be the same as any
standard distribution
• Note that in this step, only the form involving the random
variable matters. Any constants will be absorbed by the “∝” 28

BA3202
L1
Special cases

Actuarial Statistics
• Conjugate priors
• When the posterior and the prior distribution belong to the same
“general” family of distributions, this prior distribution is called
the conjugate prior.
• Conjugate distributions can be found by selecting a family of

Wenjun Zhu wjzhu@ntu.edu.sg


distribution with the same form as the likelihood function.
• Improper prior distributions
• Uninformative prior distribution: 𝑈(−∞, ∞)
• Assumes that an unknown parameter is equally likely to take any
value
• Does it make sense in practice?
• No because in this case the pdf of the prior is 0 everywhere
• In practice, usually assume a prior distribution with 𝑈(−𝑁, 𝑁)
!
where 𝑁 is a large number: 𝑓 𝜃 = 29
"=

BA3202
L1
The loss function

Actuarial Statistics
• Objective: To obtain the estimator of 𝜃

• Definitions:
• 𝑔 𝑥 : the estimator of 𝜃

Wenjun Zhu wjzhu@ntu.edu.sg


• A function of the sample
• 𝐿 𝑔 𝑥 , 𝜃 : the loss function
• Measures how much the estimates deviate from the
“true” value of 𝜃
• Expected posterior loss (EPL):
𝐸𝑃𝐿 = 𝐸 𝐿 𝑔 𝑥 , 𝜃 = ∫ 𝐿 𝑔 𝑥 , 𝜃 𝑓 𝜃 𝑥 𝑑𝜃
• Bayesian estimator: function 𝑔(𝑥) that minimizes the EPL
30

BA3202
L1
Common loss functions

Actuarial Statistics
#
• Quadratic loss: 𝐿 𝑔 𝑥 , 𝜃 = 𝑔 𝑥 − 𝜃
• Bayesian estimator: 𝑔 = 𝐸(𝜃|𝑋), mean of posterior

• Absolute error loss: 𝐿 𝑔 𝑥 , 𝜃 = 𝑔 𝑥 − 𝜃

Wenjun Zhu wjzhu@ntu.edu.sg


• Bayesian estimator: median of posterior
0, 𝑖𝑓𝑔 𝑥 = 𝜃
• “All or nothing” error: 𝐿 𝑔 𝑥 , 𝜃 = -
1, 𝑖𝑓𝑔 𝑥 ≠ 𝜃
• Bayesian estimator: mode of posterior

31

BA3202
L1
Quadratic loss function

Actuarial Statistics
• Bayesian estimator of quadratic loss function is the posterior
mean, 𝑔 = 𝐸(𝜃|𝑋).
• Scratch of proof:
"
• 𝐿 𝑔 𝑥 ,𝜃 = 𝑔 𝑥 − 𝜃

Wenjun Zhu wjzhu@ntu.edu.sg


"
• 𝐸𝑃𝐿 = ∫ 𝐿 𝑔 𝑥 , 𝜃 𝑓 𝜃 𝑥 𝑑𝜃 = ∫ 𝑔 𝑥 − 𝜃 𝑓 𝜃 𝑥 𝑑𝜃
• First order condition: take partial differentiation w.r.t. 𝑔
𝜕𝐸𝑃𝐿
= 2∫ 𝑔 − 𝜃 𝑓 𝜃 𝑥 𝑑𝜃 = 0
𝜕𝑔
⇨ 𝑔∫ 𝑓 𝜃 𝑥 𝑑𝜃 = ∫ 𝜃𝑓 𝜃 𝑥 𝑑𝜃
• Also note that,
∫ 𝑓 𝜃 𝑥 𝑑𝜃 = 1; ∫ 𝜃𝑓 𝜃 𝑥 𝑑𝜃 = 𝐸(𝜃|𝑥),
32
• Hence, 𝑔(𝑥) = 𝐸(𝜃|𝑥).
BA3202
L1
Absolute loss function

Actuarial Statistics
• Bayesian estimator under the absolute loss function is the median of the posterior.
• Scratch of proof:
• 𝐿 𝑔 𝑥 ,𝜃 = 𝑔 𝑥 − 𝜃
• 𝐸𝑃𝐿 = ∫ 𝐿 𝑔 𝑥 , 𝜃 𝑓 𝜃 𝑥 𝑑𝜃 = ∫ 𝑔 𝑥 − 𝜃 𝑓 𝜃 𝑥 𝑑𝜃
# "
= 9 (𝑔 − 𝜃)𝑓 𝜃 𝑥 𝑑𝜃 + 9 𝜃 − 𝑔 𝑓 𝜃 𝑥 𝑑𝜃
!" #
• First order condition: take partial differentiation w.r.t. 𝑔

Wenjun Zhu wjzhu@ntu.edu.sg


𝜕𝐸𝑃𝐿
𝜕𝑔
# "
= 9 𝑓 𝜃 𝑥 𝑑𝜃 + 𝑔 − 𝑔 𝑓 𝑔 𝑥 ⋅ 1 + 9 −1 ⋅ 𝑓 𝜃 𝑥 𝑑𝜃 − 𝑔 − 𝑔 𝑓 𝑔 𝑥 ⋅ 1 (∗∗∗)
!" #
# "
𝜕𝐸𝑃𝐿
⇨ = 9 𝑓 𝜃 𝑥 𝑑𝜃 − 9 𝑓 𝜃 𝑥 𝑑𝜃 = 0
𝜕𝑔 !" #
# "
⇨ ' 𝑓 𝜃 𝑥 𝑑𝜃 = ' 𝑓 𝜃 𝑥 𝑑𝜃
!" #
⇨ Pr 𝜃 ≤ 𝑔 𝑥 𝑥 = Pr(𝜃 > 𝑔(𝑥)|𝑥)
• Hence, 𝑔 𝑥 is the posterior median.

• Note that Equation (***) is because:


𝑑 ((&) ((&)
𝜕 33
9 𝑓 𝑢, 𝑥 𝑑𝑢 = 9 𝑓 𝑢, 𝑥 𝑑𝑢 + 𝑓 𝑏 𝑥 , 𝑥 𝑏) 𝑥 − 𝑓 𝑎 𝑥 , 𝑥 𝑎) 𝑥
𝑑𝑥 $(&) $(&) 𝜕𝑥
BA3202
L1
All-or-nothing loss function

Actuarial Statistics
• Bayesian estimator under the All-or-nothing loss function is the
mode of the posterior.
• Scratch of proof:
0, 𝑖𝑓𝑔 𝑥 = 𝜃
• 𝐿 𝑔 𝑥 ,𝜃 = ?
1, 𝑖𝑓𝑔 𝑥 ≠ 𝜃

Wenjun Zhu wjzhu@ntu.edu.sg


• Now consider a small neighbor around 𝜃: 𝜃 − 𝜀, 𝜃 + 𝜀 ,
• 𝐿 𝑔 𝑥 , 𝜃 becomes
0, 𝑔 − 𝜀 < 𝜃 < 𝑔 + 𝜀,
𝐿 𝑔 𝑥 ,𝜃 = ?
1, otherwise

𝐸𝑃𝐿 = ∫ 𝐿 𝑔 𝑥 , 𝜃 𝑓 𝜃 𝑥 𝑑𝜃
FHG
= 1 − ∫F+G 𝑓 𝜃 𝑥)𝑑𝜃 = 1 − 2𝜀𝑓(𝑔|𝑥) for small 𝜀
• EPL is minimized when 𝑓(𝑔|𝑥) is maximized 34
• Hence, 𝑔 𝑥 is the posterior mode.
BA3202
L1
L1

Actuarial Statistics
BA3202

You might also like