Hostname: page-component-89b8bd64d-9prln Total loading time: 0 Render date: 2026-05-08T03:06:13.775Z Has data issue: false hasContentIssue false

Computing quantities of interest and their uncertainty using Bayesian simulation

Published online by Cambridge University Press:  26 April 2022

Andreas Murr*
Affiliation:
Department of Politics and International Studies, University of Warwick, Coventry, UK
Richard Traunmüller
Affiliation:
School of Social Sciences, University of Mannheim, Mannheim, Germany
Jeff Gill
Affiliation:
Departments of Government, Mathematics & Statistics, American University, Washington, DC, USA
*
*Corresponding author. Email: a.murr@warwick.ac.uk
Rights & Permissions [Opens in a new window]

Abstract

When analyzing data, researchers are often less interested in the parameters of statistical models than in functions of these parameters such as predicted values. Here we show that Bayesian simulation with Markov-Chain Monte Carlo tools makes it easy to compute these quantities of interest with their uncertainty. We illustrate how to produce customary and relatively new quantities of interest such as variable importance ranking, posterior predictive data, difficult marginal effects, and model comparison statistics to allow researchers to report more informative results.

Information

Type
Research Note
Creative Commons
Creative Common License - CCCreative Common License - BY
This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (https://creativecommons.org/licenses/by/4.0/), which permits unrestricted re-use, distribution, and reproduction in any medium, provided the original work is properly cited.
Copyright
Copyright © The Author(s), 2022. Published by Cambridge University Press on behalf of the European Political Science Association
Figure 0

Table 1. Quantities of interested illustrated below and example research questions for which these quantities are of interest.

Figure 1

Table 2. Data and models used to illustrate quantities of interest.

Figure 2

Figure 1. The posterior density for coefficients in the hierarchical linear model of candidate ratings varies in location and spread. While candidates with a degree from a small college are rated higher than candidates with a degree from a state university, it is unclear how certain we can be of this statement (but see Figure 2).

Figure 3

Figure 2. Posterior probability of having the k-th largest effect size (“rank”) for each treatment in the hierarchical linear model of candidate ratings. Most of the first 12 ranks are highly certain. The remaining ranks are much more uncertain.

Figure 4

Figure 3. Probability of turnout at mean values (top panel replicated from King et al. (2000, Figure 1 on p. 355)) and marginal effects at observed values (bottom panel). The marginal effects unmask heterogeneity in respondents with the same age and level of education, show the location of the turnout plateau more clearly, and convey the observed values. Note: Dots represent posterior medians. Vertical bars indicate 99 percent credible intervals. In the bottom panels the age values are jittered slightly to increase readability. The horizontal dashed line indicates a marginal effect of 0.

Figure 5

Figure 4. Posterior distributions of residuals in linear model of union density to check for normality. The distributions look symmetric and conform with theoretical quantiles. Note: Grey lines/dots are 1000 simulation draws from the posterior, the black line in the right plot indicates the posterior means.

Figure 6

Figure 5. Posterior predictive checks of the logit model of turnout. The model fails to adequately capture the turnout rate among education subgroups. Note: The solid black line () shows the data and the grey lines () represent 20 simulated replications from the model.

Figure 7

Figure 6. Posterior predictive checks of the original and revised logit models of turnout. The revised model better captures the turnout rate among education subgroups. Notes as in Figure 5.

Figure 8

Figure 7. Posterior distribution and median of the Bayesian R2 in the linear model of union density.

Figure 9

Table 3. Akaike information criterion (AIC) and Watanabe–Akaike information criterion (WAIC) of logit models M1 and M2 of turnout and their difference.

Supplementary material: Link

Murr et al. Dataset

Link
Supplementary material: File

Murr et al. supplementary material

Murr et al. supplementary material

Download Murr et al. supplementary material(File)
File 3.7 KB