Bank Shot Win Analysis

There’s a carnival game at the Iolani Fair called Bank Shot. You have to roll a ball on a ramp into a hole and win a prize. Get it in the green hole and you win tickets, and if you get it in the red hole, you win a big inflatable prize. I wondered what was the rate of hitting the red and green holes.

Here’s a picture of the game layout.

Methods

I gathered data on 48 trials consisting of 2 rolls each. I calcuated the probability of hitting a green hole and hitting a red hole on each roll. I then calculated the probability of hitting a hole if the player had hit a hole on the first roll vs if they had missed on the first roll. I then calculated the overall probability of success for all 2 roll trials.

Results

Observed Probability of Outcomes

library(tidyverse)
## Loading tidyverse: ggplot2
## Loading tidyverse: tibble
## Loading tidyverse: tidyr
## Loading tidyverse: readr
## Loading tidyverse: purrr
## Loading tidyverse: dplyr
## Conflicts with tidy packages ----------------------------------------------
## filter(): dplyr, stats
## lag():    dplyr, stats
library(binom)
x <- read.csv("../datasets/bankshot.txt", sep = " ", colClasses = "character", header = F)
x <- tbl_df(x)
x$V2 <- toupper(x$V2)
y <- gather(x, "roll", "outcome", 1:2)
y$roll <- ifelse(y$roll == "V1", 1L, 2L)

First I looked at how often the balls fell into the green (G) and red (R) holes or missed a hole entirely (X). This was the frequency of each outcome.

table(y$outcome)
## 
##  G  R  X 
## 37  4 55

And this was the percentage of each outcome.

round(prop.table(table(y$outcome)), 3)
## 
##     G     R     X 
## 0.385 0.042 0.573

I generated confidence intervals for the three outcomes.

binom.estimate <- function(successes, n, method = "exact") {
  library(binom)
  p_estimate <- round(successes/n, 3)
  upper <- round(binom.confint(successes, n, method=method)$upper, 3)
  lower <- round(binom.confint(successes, n, method=method)$lower, 3)
  x <- paste0(p_estimate, " (", lower, "-", upper, ")")
  return(x)
}

The probability of getting a green hole was 37/96 or 0.385 (0.288-0.49). The probability of getting a red hole was 4/96, 0.042 (0.011-0.103). The probability of missing a hole was 55/96 or0.573 (0.468-0.673).

Conditional Probability Estimates

The next question is whether hitting a hole on the first try changed the probability of getting one on the second try. With this small number of observations, it might be hard to demonstrate this. If I look at the success rate on roll 1 vs. roll 2, it seemed like the rolls were independent. Roll 1 success rate (any hole) was 21/48, 0.438 (0.295-0.588) vs roll 2 success of 20/48, 0.417 (0.276-0.568).

table(roll=y$roll, outcome=y$outcome)
##     outcome
## roll  G  R  X
##    1 19  2 27
##    2 18  2 28

However, when I looked at the success rate on roll 2 based on whether the player had a ball hit on roll 1, a different picture developed.

z <- mutate(x, success1 = ifelse(V1 == "X", F, T))
table(z$success1, z$V2)
##        
##          G  R  X
##   FALSE 13  1 13
##   TRUE   5  1 15

If the player hit on roll 1, they hit on roll 2 as well 6/21 times, 0.286 (0.113-0.522). If they did not hit on roll 1, they hit on roll 2 14/27 times, 0.519 (0.319-0.713). This seemed to suggest that the hits were not independent. This made sense since the first roll occupies one of the holes, leaving one fewer spot for a success on the second roll.

Because they weren’t independent, I calculated the probability of giving out tickets or a prize for each set of victories.

z <- mutate(x, green = ifelse((V1 == "G" | V2 == "G") & (V1 != "R" | V2 != "R"), T, F),
       red = ifelse(V1 == "R" | V2 == "R", T, F))
table(green = z$green)
## green
## FALSE  TRUE 
##    16    32
table(red = z$red)
## red
## FALSE  TRUE 
##    44     4

A player got a green ball 32/48 times, 0.667 (0.516-0.796), and a red ball 4/48 times, 0.083 (0.023-0.2).

Discussion

For 2 ball trials, about 2/3 of players hit a green ball and win tickets. About 1/12 of players hit a red hole and win a inflatable prize. To hit our goal of giving away about 12 prizes an hour, we would need to attract 144 games/hour. Even with two game tables, this means more than one game per minute. It’s possible but unlikely.

What would happen if we went to 3 balls (as we were doing earlier in the day)? More players would likely get a green and more players would also get a red. Without knowing the conditional probability for the third ball, it’s not possible to estimate the rate of tickets or prize giveaways.

If you hit a green on the first ball, is it more likely for you to hit a red on the second ball? I needed more data to establish this, but it would seem possible. The ball might bounce off the ball in a green hole and roll into a red hole more easily.

Conclusion

For 2 ball trials on Bank Shot, about 2/3 of players hit a green ball and win tickets. About 1/12 of players hit a red hole and win a inflatable prize.

games