Statistical Modelling Notes
Statistical Modelling Notes
Statistical Modelling
Vasiliki Koutra
Department of Mathematics, King’s College London
Contents
1 Introduction to Statistical Modelling 2
1.1 Linear Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
3 Estimation 4
3.1 Least squares estimation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
3.2 Maximum likelihood estimation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.3 Properties of least squares estimators . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.4 Gauss–Markov Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
5 Prediction 14
7 Model Checking 16
7.1 Coefficient of Determination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
7.2 Residual plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.3 Normal probability plot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
7.4 Other residual plots . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
7.5 Transformation of the response . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
7.6 Box–Cox transformation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
1
7.7 Outliers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2
levels (or categories) of one or more explanatory variables, e.g., simple linear regression (SLR):
ind
Yi ∼ N (β0 + β1 xi , σ 2 ), i = 1, 2, . . . , n .
µi = β1 φ1 (xi ) + · · · + βp φp (xi ),
where φj (xi ) are known basis functions. The model is linear in the parameters β1 , . . . , βp .
Examples:
• µi = β0 + β1 xi . This is simple linear regression with basis functions φ0 (x) = 1, φ1 (x) = x.
• µi = β0 + β1 xi + β11 x2i (φ0 (x) = 1, φ1 (x) = x, φ11 (x) = x2 ). This is quadratic regression
with basis functions φ0 (x) = 1, φ1 (x) = x, φ11 (x) = x2 .
• µi = β0 + β1 x1i + β2 x2i . This is multiple linear regression (with two explanatory variables)
with basis functions φ0 (x) = 1, φ1 (x) = x1 , φ2 (x) = x2 .
• µi = β0 + β1 Z1i + β2 Z2i with Z1i = 1 if Ti = 1, 0 otherwise; Z2i = 1 if Ti = 2, 0 otherwise.
This corresponds to a one-way ANOVA model with three groups (levels 0, 1, 2) and basis
functions φ0 (T ) = 1, φ1 (T ) = Z1 , φ2 (T ) = Z2 .
with
Var(Yi ) = σ 2 , Cov(Yi , Yi0 ) = 0 .
We make no assumptions about the distribution of Yi beyond the first two moments.
The general linear model can be written
Y = Xβ + ε, E(ε) = 0, Var(ε) = σ 2 I ,
where
Y1 β1 ε1 φ1 (x1 ) φ2 (x1 ) · · · φp (x1 )
Y2 β2 ε2 φ1 (x2 ) φ2 (x2 ) · · · φp (x2 )
Y = . , β = . , ε = . , X= . .. .
..
.. .. .. .. . .
Yn βp εn φ1 (xn ) φ2 (xn ) · · · φp (xn )
3
adds the assumption of normality for the errors, where Nn (µ, Σ) denotes an n-dimensional
multivariate normal distribution with expectation µ and variance-covariance matrix Σ.
Aside: A k × 1 random vector A with joint p.d.f. of A1 , A2 , . . . , Ak given by
−k/2 −1/2 1 > −1
fA (a; µ, Σ) = (2π) |Σ| exp − (a − µ) Σ (a − µ) ,
2
Here I is the n × n identity matrix. Note that Cov(Yi , Yj ) = Cov(Yj , Yi ), so the variance-
covariance matrix is symmetric.
3 Estimation
3.1 Least squares estimation
Y = Xβ + ε , E(ε) = 0 , Var(ε) = σ 2 I ,
ŷ = Xβ̂.
The idea of least squares is that we want ŷi to be close to yi . We choose β to minimise
n
X
S(β) = (yi − µi )2 = (y − µ)> (y − µ) .
i=1
Substituting µ = Xβ,
4
Aside: if u is a scalar and v is a vector
∂u
∂v
∂u . 1
= .. .
∂v ∂u
∂vt
∂S
= −2X> y + 2X> Xβ = 0 .
∂β
This give us the normal equations:
X> Xβ̂ = X> y
If X> X is non-singular,
β̂ = (X> X)−1 X> y.
The second derivative is 2X> X, which is positive definite if X> X is non-singular, so the sta-
tionary point is a minimum.
Example
for a given data vector y. The least squares estimator (LSE) is the random vector
5
3.2 Maximum likelihood estimation
Y ∼ Nn (Xβ, σ 2 I) ,
(y − Xβ)> (y − Xβ) ,
which is the same as the least squares criterion. Hence, the maximum likelihood estimate (MLE)
of β is the same as the LSE, i.e.,
Proof.
E(β̂) = E[(X> X)−1 X> Y] = (X> X)−1 X> E(Y) = (X> X)−1 X> Xβ = β.
Proof.
Var(β̂) = Var[(X> X)−1 X> Y] = (X> X)−1 X> Var(Y)X(X> X)−1 = σ 2 (X> X)−1 .
We want to show that V ar(β̂) is “small”. We can use the Gauss–Markov theorem, which applies
to any estimable linear function of β,
`> β = `1 β1 + `2 β2 + · · · + `p βp ,
where ` = (`1 , `2 , . . . , `p )> is a known vector of constants. Note that `> β̂ is an unbiased
estimator of `> β and that
`> β̂ = `> (X> X)−1 X> Y
is a linear function of Y.
6
Theorem 3.1 (Gauss–Markov Theorem). Let `> β be an estimable function. Then `> β̂ has
minimum variance among all linear (in Y) unbiased estimators of `> β.
Proof. Symmetry:
(I − H)> = I> − H> = I − H .
Idempotency:
(I − H)2 = I − 2H + H2 = I − 2H + H = I − H .
Then,
Var(c> Y) − Var(`> β̂) = σ 2 c> (I − H)c .
Since I − H is symmetric and idempotent,
c> (I − H)c ≥ 0 ,
so
Var(c> Y) ≥ Var(`> β̂) .
Hence `> β̂ has minimum variance among all linear unbiased estimators of `> β.
We say that β̂ is a minimum variance linear unbiased estimator (MVLUE) of β, or a best linear
unbiased estimator (BLUE) of β.
Note:
• A special case of the Gauss–Markov theorem is that each β̂j has minimum variance among
all linear unbiased estimators of βj .
• µ̂(x0 = x> >
0 β̂ is a BLUE of µ(x0 ) = φ(x0 ) β, where
φ1 (x0 )
φ2 (x0 )
φ(x0 ) = . .
..
φp (x0 )
7
4 Inference in linear models
Recall that the LSE is
β̂ = (X> X)−1 X> Y ,
with E(β̂) = β and Var(β̂) = σ 2 (X> X)−1 . Also note that β̂ is a linear function of Y.
Hence, if the normal linear model holds, i.e., Y ∼ Nn (Xβ, σ 2 I), then β̂ is a linear function of
a multivariate normal random vector, so β̂ is also multivariate normal:
β̂ ∼ Np β, σ 2 (X> X)−1 .
Practical implications
β̂j − βj
∼ N (0, 1), j = 1, 2, . . . , p
σ 2 vjj
This could be used to construct hypothesis tests and confidence intervals (CIs) for βj , if σ 2 were
known. However, in practice σ 2 is unknown.
4.2 Estimating σ 2
It seems reasonable to base the estimate of σ 2 on the attained minimum value of S(β), namely
S(β̂) is called the residual sum of squares (RSS or SSRes ) or error sum of squares (SSE ).
As usual, we also define a random variable,
8
Proof.
E(SSE ) = E[Y> (I − H)Y] = E[tr(Y> (I − H)Y)] .
Aside: Recall for matrices A and B of appropriate size, tr(AB) = tr(BA). Also, Var(Y) =
E(YY> ) − E(Y)E(Y)> .
Hence,
E(SSE ) = tr[(I − H)E(YY> )] = tr[(I − H)(Var(Y) + E(Y)E(Y)> )] .
Since Var(Y) = σ 2 I and E(Y) = Xβ,
But HX = X, so
tr[(I − H)Xββ > X> ] = 0 .
Also, tr(I − H) = n − tr(H) = n − p. Thus,
E(SSE ) = (n − p)σ 2 .
SSE
Corollary 4.1. n−p is an unbiased estimator of σ 2 .
Definition 4.1.
SSE
s2 = MSE =
n−p
is called the mean square error or residual mean square.
β̂j − βj0
p = Tj .
s2 vjj
Definition 4.2. ei = yi − ŷi is the ith residual, and e = y − ŷ is the vector of residuals.
Note:
1. e = y − ŷ = y − Hy = (I − H)y.
2. We use e to denote both the random vector (I − H)Y and its realised value.
9
It follows that
SSE = e> e .
Proof.
e = Y − Ŷ = Xβ + ε − H(Xβ + ε) = (I − H)ε .
Proof.
1. Each ei is a linear function of the normal random vector ε, so e is multivariate normal.
2. E(e) = E[(I − H)ε] = (I − H)E(ε) = 0.
3. Var(e) = (I − H)Var(ε)(I − H)> = σ 2 (I − H).
Lemma 4.2. For a symmetric idempotent matrix A of rank r, there exists an orthogonal matrix
C such that A = CDC> , where
Ir 0
D= .
0 0
(n − p)s2
∼ χ2n−p .
σ2
Proof.
(n − p)s2 SSE e> e ε> (I − H)ε
= = = .
σ2 σ2 σ2 σ2
Hence, we can write
(n − p)s2 ε> CDC> ε (C> ε)> D(C> ε)
= = .
σ2 σ2 σ2
Let Z = C> ε/σ. Then,
(n − p)s2
= Z> DZ .
σ2
As ε ∼ Nn (0, σ 2 I) and C is orthogonal, Z ∼ Nn (0, I). Thus,
n−p
(n − p)s2 X 2
= Zi ∼ χ2n−p .
σ2
i=1
10
Aside: A chi-squared random variable with r degrees of freedom is the distribution of the sum of
squares of r independent standard normal random variables. If Z1 , Z2 , . . . , Zr ∼ i.i.d. N (0, 1),
then
Xk
Zi2 ∼ χ2r .
i=1
We have
β̂j − βj
p ∼ N (0, 1) ,
σ 2 vjj
and, independently,
(n − p)s2
∼ χ2n−p .
σ2
Hence,
β̂j −βj
√
σ 2 vjj β̂j − βj
q =p ∼ tn−p .
(n−p)s2
2
s2 vjj
σ (n−p)
This result is used to obtain confidence intervals for βj and to test hypotheses such as H0j :
p
βj = 0 against H1j : βj 6= 0. Recall that s2 vjj is the estimated standard error (s.e.) of β̂j .
We can test H0j : βj = βj0 , usually βj0 = 0, using the test statistic
β̂j − βj0
Tj = p .
s2 vjj
11
4.5 Confidence interval for an individual parameter
Since
β̂j − βj
p ∼ tn−p ,
s2 vjj
we have: !
β̂j − βj
P −tn−p, 1−α/2 ≤p ≤ tn−p, 1−α/2 = 1 − α.
s2 vjj
Rearranging:
q q
P β̂j − tn−p, 1−α/2 s2 vjj ≤ βj ≤ β̂j + tn−p, 1−α/2 s2 vjj . = 1 − α .
p
Since s.e.(β̂j ) = s2 vjj , the 100(1 − α)% CI is:
h i
β̂j − tn−p, 1−α/2 s.e.(β̂j ), β̂j + tn−p, 1−α/2 s.e.(β̂j ) .
A company operates portrait studios, specialising in children’s portraits, in 21 cities. They want
to investigate whether sales (Y , $’000) depend on the number of people under 16 in the city
(x1 , ’000) and per capita income (x2 , $’000). They have data for each city.
The multiple regression model:
Yi = β0 + β1 x1i + β2 x2i + εi
β̂1 1.4546
t1 = = = 6.8678
s.e.(β̂1 ) 0.2118
There is overwhelming evidence against H01 , so sales are related to the number of children in
the city.
To test H02 : β2 = 0 vs HA2 : β2 6= 0, we use:
β̂2 9.3655
t2 = = = 2.3045
s.e.(β̂2 ) 4.0640
Critical values:
12
Since 2.101 < 2.3045 < 2.878, we reject H02 at α = 5% but not at α = 1%.
The p-value is:
p = 2 [1 − P (T2 ≤ 2.3045)] = 2 [1 − 0.9833] = 0.0334.
Thus, there is moderate evidence that income is related to sales.
Note: These tests only make sense for this model. We are asking:
(i) Does the number of children have any relationship with sales, given the relationship of
income with sales?
That is, we are comparing the models:
not
E(Yi ) = β0 + β1 x1i with E(Yi ) = β0
(ii) Does income have any relationship with sales, beyond what is explained by the number
of children?
A 95% CI for β1 is
β̂1 ± tn−p, 1−α/2 s.e.(β̂1 )
1.4546 ± t18, 0.975 × 0.2118
1.4546 ± 2.101 × 0.2118
[1.0096, 1.8996]
Each increase of 1 child (in thousands) in a city is associated with increased sales of between
$1.01k and $1.90k.
As µ0 = µ(x0 ) = x>0 β. inferences for the expected response at some particular values, x0 , of
the explanatory variables are easily obtained. The point estimator of µ0 is
µ̂0 = x>
0 β̂ .
E(µ̂0 ) = x>
0 β = µ0 ,
Var(µ̂0 ) = Var(x> 2 > > −1
0 β) = σ x0 (X X) x0 .
13
5 Prediction
To predict an actual future observation Y0 at x0 , we use Ŷ0 = x> 0 β̂ = µ̂0 . Because we must
account for the variation in the observation, a confidence interval for µ0 is not adequate; instead
we use a prediction interval.
We have
Y0 ∼ N (µ0 , σ 2 ) ,
but µ0 is unknown. We also have
Hence
Ŷ0 − Y0 = µ̂0 − Y0 ∼ N 0, σ 2 x> > −1
0 (X X) x0 + 1 ,
Then,
Ŷ0 − Y0
q ∼ tn−p ,
> > −1
s x0 (X X) x0 + 1
and a 100(1 − α)% prediction interval for Y0 is
q
Ŷ0 ± tn−p; 1−α/2 s x> > −1
0 (X X) x0 + 1 .
14
Theorem 6.1 (ANOVA identity).
We know that SST is related to a χ2n−1 distribution, and SSE is related to a χ2n−p distribution.
We can interpret the corresponding degrees of freedom (d.f.) as “pieces of information” contained
in the sums of squares. The n observations contribute n − 1 pieces of information about the
total variability (since we estimate ȳ from the data). Fitting the regression model uses up p − 1
pieces of information (since we estimate p parameters, including the intercept), leaving n − p
pieces of information to estimate the residual variability.
We present all of this in the analysis of variance table:
Let β = (β0 , β1 , . . . , βp−1 )> and denote by β1 = (β1 , . . . , βp−1 )> the coefficients of the explana-
tory variables (excluding the intercept).
(p − 1)M SR SSR
Corollary 6.1. If β1 = 0, then 2
= 2 ∼ χ2p−1 .
σ σ
(W1 /ν1 )
Aside (distribution theory). If W1 ∼ χ2ν1 and W2 ∼ χ2ν2 are independent, then ∼ Fν1 ,ν2 .
(W2 /ν2 )
Since
(p − 1)M SR M SR
2
/(p − 1) =
σ σ2
and
(n − p)M SE M SE
2
/(n − p) = ,
σ σ2
the following result follows.
15
Theorem 6.3. If β1 = 0, then M SR and M SE are independent, and
M SR
F = ∼ Fp−1, n−p .
M SE
This is called the (global) F -test (named after R. A. Fisher, who formalised it in 1921). The
test statistic F = M SR /M SE is the variance ratio in the ANOVA table.
Under H0 , F ∼ Fp−1, n−p . We reject H0 at level α if the observed value of F is sufficiently large.
Specifically, reject H0 at level α if
F ≥ Fp−1, n−p; 1−α .
In practice the global F -test is performed before testing individual parameters.
1. If H0 is not rejected, no further analysis is usually needed.
2. More formally, this guards the Type-I error rate against multiple testing (a single test
with P (Type I error) = α).
7 Model Checking
We have seen how to fit models and do inference on parameters. However, this estimation
and inference is conditional on an assumed model. An obvious question is whether the model
is appropriate for the data. That is, does it capture the main features of the process which
generated the data. In particular, are the assumptions of the form of the mean relationship,
constant variance, uncorrelated observations and normality at least a reasonable approximation?
2
0 ≤ R ≤ 1.
For simple linear regression (only), R2 equals the squared sample correlation between x and
y. In general, R2 is interpreted as the proportion of variability in y1 , . . . , yn explained by the
model fitted.
An R2 ≥ 90% is considered good and R2 ≥ 70% satisfactory, if all other aspects of the model
are acceptable.
If R2 ≤ 70%, the model will have low predictive power but may still indicate relationships
between E(Y ) and the explanatory variables. Note that R2 can always be inceased by adding
more terms to the model and any model with n parameters has R2 = 100%.
A large R2 does not mean the model is good and a low R2 does not mean the model is poor. It
only tells us about one aspect of model fit.
16
7.2 Residual plots
We have defined the (raw) residuals as ei = yi − ŷi , i = 1, . . . , n, and showed that E(ei ) =
0 and Var(ei ) = (1 − hii )σ 2 , where hii is the ith diagonal element of the hat matrix H =
X(X> X)−1 X> .
Aproximately, ri ∼ N (0, 1). The ri are correlated but for large samples, hij (i 6= j) is small so
that approximately they behave like i.i.d. draws for large.
We can check the assumption of constant variance, against the alternative that it varies with
the expected response, by plotting ri against ŷi . We should see a random scatter of points on
either side of ri = 0; see Figure 1.
ri
ri = 0
ŷi
Figure 1: Residuals vs fitted values: ri against ŷi : random scatter about 0 indicates constant
variance.
If the variance increases with expectation, we will see more scatter for larger ŷi (a funnel shape);
see Figure 2.
ri
ri = 0
ŷi
Figure 2: Residuals vs fitted values: ri against ŷi showing increasing variance (funnel shape).
17
7.3 Normal probability plot
We plot z(k) against Φ−1 ((k − 12 )/n). If the zi are approximately standard normal, the points
should lie approximately on the 45◦ line through the origin. Departures from this line indicate
departures from normality.
A normal probability plot of r[ k], the ordered standardised residuals, allows us to check the
assumption of normalty; see Figure 3.
We can plot the standardised residuals against the explanatory variables to check for non-
linearity in the mean relationship or to see if the variance changes with any of the explanatory
variables; see Figure 4.
If the data are collected over time, we can plot the standardised residuals against time to check
for evidence of time trends or autocorrelation; see Figure 5.
Note:
1. We are looking for large departures from assumptions.
2. Variation on the horizontal axis tells us nothing about model adequacy.
3. We should produce these plots routinely when fitting linear models.
18
Z(k)
Normal Positive skewness
Figure 3: Normal probability plot sketches: (top-left) approximately normal; (top-right) positive
skew; (bottom) heavy tails. The red line is the 45◦ reference.
We often round λ̂ to a simple rational number for [Link] way to judge how to round
is to construct a 95% confidence interval for λ using the profile log-likelihood; any convenient
value inside this interval is acceptable.
19
(i) No evidence of nonlinearity or nonconstant variance (ii) Quadratic nonlinearity
ri∗ ri∗
r∗ = 0 r∗ = 0
xi xi
r∗ = 0
xi
Figure 4: Three diagnostic plots of standardised residuals ri∗ against an explanatory variable
x: (i) no evidence of nonlinearity or nonconstant variance; (ii) quadratic nonlinearity; (iii)
non-constant variance (funnelling).
To see the effect of the transformaton, consider λ = 0, i.e., the log transformation:
Thus the errors are multiplicative on the original scale; the variance increases with the expec-
tation; and if εi ∼ N (0, σ 2 ) then Yi is log-normal (positively skewed).
√
Occasionally, other transformations are used, e.g., sin−1 ( Yi ) for proportions.
7.7 Outliers
An outlier is an observation whose response does not fit the pattern of the rest of the data. In
linear models an outlier has a large positive or negative residual. Some software flag potential
20
(i) ok (ii) time trend
ri∗ ri∗
r∗ = 0 r∗ = 0
ti ti
(iii) autocorrelation
ri∗
r∗ = 0
ti
Figure 5: Three diagnostic plots of standardised residuals ri∗ against time t: (i) no evidence of
time trend or autocorrelation; (ii) time trend; (iii) autocorrelation.
outliers with |ri | > 2 or |ri | > 3 (with standardised residuals ri ); in large samples such rules
flag too many points. Outliers will show up in any of the residual plots.
If we find an outlier, we should:
1. check whether the observation has been recorded or copied incorrectly; if so, correct or
delete it;
2. check if the sampled unit is somehow different in kind from the rest; if so, remove the
observation but note that the analysis then applies only to the main population;
3. if neither applies, repeat the analysis excluding the observation and report both analyses
if conclusions differ.
Be wary of labelling outliers: some observation will always have the largest residual due to
random variation; the ones that matter are those that actually change conclusions. If the model
is inadequate, spurious outliers may appear.
21
8 Problems in fitting regression models
8.1 Leverage
Observations which have unusual x values do not indicate anything wrong with the model or
the data (as long as it has been recorded correctly) but can affect the fitted model.
Let H = X(X> X)−1 X> be the hat matrix. Then ŷ = Hy, so for the ith fitted value
n
X X
ŷi = hij yj = hii yi + hij yj .
j=1 j6=i
Usually hij , i 6= j, are small relative to hii , hii indicates how much yi contributes to ŷi and is
called the leverage of (xi , yi ). It measures the remoteness of xi in the covariate space.
Note that
n
X
hii = tr(H) = tr X(X> X)−1 X> = tr(Ip ) = p.
i=1
Hence the mean leverage is p/n. If hii > 2p/n the leverage is large enough to warrant attention;
hii > 3p/n is very large.
A point with high leverage is potentially influential (it may exert a disproportionate effect on
the fitted line). Actual influence is measured using Cook’s distance.
(i)
where ŷj is the fitted value for yj when the ith observation is removed, s2 is the mean square
error, and p the number of parameters (including the intercept). A large Di indicates that the
ith observation is influential.
A useful identity for the leave-one-out estimator relates β̂ (i) , the estimate of β with the ith
observation removed, to β̂, the estimate using all data:
ei (X> X)−1 xi
β̂ (i) = β̂ − .
1 − hii
From this expression, we can derive an alternative formula for Cook’s distance:
ri2 hii
Di = ,
p (1 − hii )
p
where ri = ei / (1 − hii ) s2 is the standardised residual.
The influence of the ith observation depends on both the residual size and the leverage. An
influential observation signals a problem caused by the data and cannot be “fixed” by further
analysis.
8.3 Multicollinearity
If X> X is singular we cannot obtain unique least squares estimates. Singularity arises when
one column of X is a linear combination of other columns (column rank < p). If X> X is nearly
singular (one column is nearly a linear combination of others), the following problems arise:
22
1. numerical procedures for inverting X> X can fail or be inaccurate/unstable;
2. estimates are sensitive to small changes in the data (e.g. rounding);
3. some estimators are highly correlated so different models may fit equally well;
4. parameter estimators have large variances.
One way to detect this multicollinearity is to compute the variance inflation factor (VIF) for
each covariate. For j ∈ {1, . . . , q}, regress xj on the remaining covariates x1 , . . . , xj−1 , xj+1 , . . . , xq
and let Rj2 be the resulting coefficient of multiple determination. Then
1
VIFj = .
1 − Rj2
If Rj2 = 0 (i.e. xj is orthogonal to the other covariates), VIFj = 1; if Rj2 = 1 (i.e. xj is an exact
linear combination of the others), VIFj = ∞. A common rule of thumb is that multicollinearity
is serious if VIFj > 10 for any j ∈ {1, . . . , q}. This is a property of the data, not a flaw of the
model itself.
One suggested solution for multicolinearity is ridge regression, where we use the estimator
β̂R = (X> X + λI)−1 X> y, λ > 0,
with λ chosen as small as possible while avoiding large variance inflation. A more formal ap-
proach is to use Bayesian linear models, where prior or external information on β is incorporated
through a prior distribution.
23