5.9 Pairwise Prop Test

library(tidyverse)
M <- 3573
F <- 4177
dat <- tribble(
  ~gender, ~src, ~Y, ~N,
  "Male", "Indeed", 1699, M-1699,
  "Male", "LinkedIn", 1755, M-1755,
  "Male", "Google", 1578, M-1578,
  "Female", "Indeed", 2554, F-2554,
  "Female", "LinkedIn", 1914, F-1914,
  "Female", "Google", 1694, F-1694
)
prop.test(x = dat$Y, n = dat$Y + dat$N)
## 
##  6-sample test for equality of proportions without continuity correction
## 
## data:  dat$Y out of dat$Y + dat$N
## X-squared = 412.66, df = 5, p-value < 2.2e-16
## alternative hypothesis: two.sided
## sample estimates:
##    prop 1    prop 2    prop 3    prop 4    prop 5    prop 6 
## 0.4755108 0.4911839 0.4416457 0.6114436 0.4582236 0.4055542
pairwise.prop.test(x = dat$Y, n = dat$Y + dat$N)
## 
##  Pairwise comparisons using Pairwise comparison of proportions 
## 
## data:  dat$Y out of dat$Y + dat$N 
## 
##   1       2       3       4       5      
## 2 0.40250 -       -       -       -      
## 3 0.02026 0.00021 -       -       -      
## 4 < 2e-16 < 2e-16 < 2e-16 -       -      
## 5 0.40250 0.02026 0.40250 < 2e-16 -      
## 6 6.3e-09 4.8e-13 0.00873 < 2e-16 1.1e-05
## 
## P value adjustment method: holm