17 R simulations
R simulations can be used to answer interesting questions.
In 2015, Evangelisto Ramos was convicted by a 12-member Louisiana jury in which 10 jurors voted to convict and 2 jurors voted to not convict. Ramos challenged his conviction, arguing that the U.S. Constitution requires state juries to be unanimous to convict.
In 2019, at oral arguments for the U.S. Supreme Court case Ramos v. Louisiana, Justice Samuel Alito raised a statistical issue about the likelihood of acquittal, which refers to the likelihood that a criminal defendant is found to be not guilty:
“So if you hypothesize a jury pool with a certain percentage of jurors who were inclined to acquit, and you ask is there a greater likelihood of acquittal with a 6-0 verdict than a 10-2 verdict or an 11-1 verdict…”
Let’s address this with a simulation that compares the likelihood of conviction if all 6 members of a 6-member jury must vote to convict, to the likelihood of conviction if only 10 members of a 12-member jury must vote convict.
But before we get to the simulation, which would you prefer if you were a defendant in a criminal trial?
- You are convicted only if all 6 jurors on a 6-member jury vote to convict
- You are convicted only if at least 10 jurors on a 12-member jury vote to convict
Okay, let’s get the simulation…
First, let’s construct a jury pool in which 90% of potential jurors will vote to convict:
N <- 100000
PROB.GUILTY <- 0.9
PROB.NOTGUILTY <- 1 - PROB.GUILTY
JURY.POOL <- c(rep.int(1, round(PROB.GUILTY * N)), rep.int(0, round(PROB.NOTGUILTY * N)))
ftable(JURY.POOL)## JURY.POOL 0 1
##
## 10000 90000
Now, let’s randomly select six jurors, and check whether the 6-member jury is unanimous. Let’s do this 10,000 times, and then calculate the percentage of the time that the 6-member jury unanimously convicts the defendant:
SIMULATIONS <- 10000
LIST <- rep.int(NA, SIMULATIONS)
for (i in 1:SIMULATIONS){
if(sum(sample(JURY.POOL, 6, replace = FALSE)) == 6){
LIST[i] <- 1
} else {
LIST[i] <- 0}
}
100 * sum(LIST) / SIMULATIONS## [1] 53.07
So, if each member of the jury pool has a 90% chance of voting to convict, then the defendant will be convicted by about 53% of juries, assuming that the jurors do not influence each other.
Now, let’s randomly select 12 jurors, and check whether at least 10 of the 12 jurors would vote to convict the defendant. Let’s do this 10,000 times, and then calculate the percentage of the time that the 12-member jury convicts the defendant:
SIMULATIONS <- 10000
LIST <- rep.int(NA, SIMULATIONS)
for (i in 1:SIMULATIONS){
if(sum(sample(JURY.POOL, 12, replace = FALSE)) >= 10){
LIST[i] <- 1
} else {
LIST[i] <- 0}
}
100 * sum(LIST) / SIMULATIONS## [1] 88.72
So, if each member of the jury pool has a 90% chance of voting to convict, then the defendant will be convicted by about 89% of juries, assuming that the jurors do not influence each other. So a criminal defendant would be better off facing a 6-member jury that must be unanimous to convict than a 12-member jury that can convict with at least 10 jurors.
Let’s check what happens for each percentage of the jury pool that would vote to convict, from 0 percent to 100 percent:
LIST.JURY06 <- c()
LIST.JURY12 <- c()
LIST.PROB <- c()
for (j in 0:100){
N <- 100
PROB.GUILTY <- j/100
PROB.NOTGUILTY <- 1 - PROB.GUILTY
JURY.POOL <- c(rep.int(1, round(PROB.GUILTY * N)), rep.int(0, round(PROB.NOTGUILTY * N)))
ftable(JURY.POOL)
LIST.PROB[j] <- PROB.GUILTY
SIMULATIONS <- 10000
LIST06 <- c()
LIST12 <- c()
for (i in 1:SIMULATIONS){
if(sum(sample(JURY.POOL, 6, replace = FALSE)) == 6){
LIST06[i] <- 1
} else {
LIST06[i] <- 0}
LIST.JURY06[j] <- 100 * sum(LIST06) / SIMULATIONS
if(sum(sample(JURY.POOL, 12, replace = FALSE)) >= 10){
LIST12[i] <- 1
} else {
LIST12[i] <- 0}
LIST.JURY12[j] <- 100 * sum(LIST12) / SIMULATIONS
}
}
library(tidyverse)
theme.z <- theme(
axis.text.x = element_text(size = 15, color = "black", margin = margin(t = 8,b = 8)),
axis.text.y = element_text(size = 15, color = "black", margin = margin(l = 0,r = 8)),
axis.ticks.x = element_blank(),
axis.ticks.y = element_blank(),
axis.title.x = element_text(size = 15, color = "black", margin = margin(t = 8, b = 8)),
axis.title.y = element_blank(),
panel.background = element_rect(linewidth = 0.5, color = "black", fill = "gray90", linetype = "solid"),
panel.border = element_rect(linewidth = 1.0, color = "black", fill = NA , linetype = "solid"),
panel.grid.major.x = element_blank(),
panel.grid.major.y = element_line(color = "white"),
panel.grid.minor.x = element_blank(),
panel.grid.minor.y = element_blank(),
panel.spacing.x = unit(2, "lines"),
panel.spacing.y = unit(1, "lines"),
plot.background = element_rect(fill = "white"),
plot.caption = element_text(size = 10, hjust = 0, margin = margin(t = 8)),
plot.margin = unit(c(0.5,0.5,0.5,0.5),"cm"),
plot.subtitle = element_text(size = 15, hjust = 0.5, margin = margin(b = 7)),
plot.title = element_text(size = 18, hjust = 0.5, face = "bold", margin = margin(t = 0, b = 12)),
strip.background = element_rect(linewidth = 1, color = "black", fill = "black"),
strip.text.x = element_text(size = 17, color = "white", face = "bold", margin = margin(t = 7.5, b = 7.5))
)
DATA <- data.frame(LIST.PROB, LIST.JURY06)
ggplot(DATA, aes(x = 100 *LIST.PROB, y = LIST.JURY06)) +
geom_point(size = 3.5, pch = 21, col = "black", bg = "red3", stroke = 1.2) +
geom_point(aes(x = 100 * LIST.PROB, y = LIST.JURY12), size = 3.5, pch = 21, col = "black", bg = "dodgerblue", stroke = 1.2) +
scale_x_continuous(breaks = seq(0,100,10), limits = c(0,100)) +
scale_y_continuous(breaks = seq(0,100,25), limits = c(0,100)) +
labs(x = "Percentage in the jury pool that would vote to convict", title = "Probability of a conviction...") +
annotate("text", x = 27, y = 31, hjust = 0, vjust = 0, size = 4.5, label = "...from 10, 11, or 12 jurors\non a 12-member jury") +
annotate("text", x = 100, y = 3, hjust = 1, vjust = 0, size = 4.5, label = "...from a\nunanimous\n6-member jury") +
theme.z