Chapter 7 Effects on winners

This chapter runs the same analysis on the winners. Unexpectedly, it is the winners who increase the fairness perceptions when a losing actor primes the respondents about being a good democratic citizen.

if(!require("broom")){install.packages("broom");  library(broom)}
if(!require("haven")){install.packages("haven");  library(haven)}
if(!require("here")){install.packages("here");  library(here)}
if(!require("knitr")){install.packages("knitr");  library(knitr)}
if(!require("kableExtra")){install.packages("kableExtra");  library(kableExtra)}
if(!require("naniar")){install.packages("naniar");  library(naniar)}
if(!require("tidyverse")){install.packages("tidyverse");  library(tidyverse)}

set.seed(2016)

d <- read_sav("C:\\Users/Sveinung/OneDrive/NORCE 2018-/goodloser/Conjoint/Bookdown-goodloser/Data/Goodloser-exp3.sav")

knitr::opts_chunk$set(echo = TRUE, knitr.kable.NA = "", cache = FALSE, warning = FALSE)

7.1 Prepare data

main_01 <- d %>% 
  mutate(rsp_id = as.numeric(responseid),
         rsp_beg = case_when(r13pad1 == 1 ~ "In favour of ban on begging",
                             r13pad1 == 2 ~ "Against ban on begging"),
          rsp_beg_imp = case_when(r13pad2 %in% 1:2 ~ "Important",
                                  r13pad2 %in% 3:5 ~ "Not important"),
         rsp_toll = case_when(r13pad3 == 1 ~ "In favour of road toll increase of diesel cars",
                              r13pad3 == 2 ~ "Against road toll increase of diesel cars"),
         rsp_toll_imp = case_when(r13pad4 %in% 1:2 ~ "Important",
                                  r13pad4 %in% 3:5 ~ "Not important"),
         treat_outcome = case_when(r13pad5_utfall == 1 ~ "The Yes side won the vote",
                                 r13pad5_utfall == 2 ~ "The No side won the vote"),
         treat_outfav = case_when(r13pad5_sak == 1 & r13pad1 == 1 & r13pad5_utfall == 1 ~ "Favorable outcome",
                                  r13pad5_sak == 1 & r13pad1 == 2 & r13pad5_utfall == 2 ~ "Favorable outcome",
                                  r13pad5_sak == 1 & r13pad1 == 1 & r13pad5_utfall == 2 ~ "Unfavorable outcome",
                                  r13pad5_sak == 1 & r13pad1 == 2 & r13pad5_utfall == 1 ~ "Unfavorable outcome",
                                  r13pad5_sak == 2 & r13pad3 == 1 & r13pad5_utfall == 1 ~ "Favorable outcome",
                                  r13pad5_sak == 2 & r13pad3 == 2 & r13pad5_utfall == 2 ~ "Favorable outcome",
                                  r13pad5_sak == 2 & r13pad3 == 1 & r13pad5_utfall == 2 ~ "Unfavorable outcome",
                                  r13pad5_sak == 2 & r13pad3 == 2 & r13pad5_utfall == 1 ~ "Unfavorable outcome"),
         treat_issue = case_when(r13pad5_sak == 1 ~ "Ban on begging",
                               r13pad5_sak == 2 ~ "Road toll increase of diesel cars"),
         treat_winningmargin = case_when(r13pad5_vinnermargin == 1 ~ "Not shown",
                                       r13pad5_vinnermargin == 2 ~ "Slight majority",
                                       r13pad5_vinnermargin == 3 ~ "Large majority"),
         treat_winnergloat = case_when(r13pad5_vinner == 1 ~ "Not shown",
                                     r13pad5_vinner == 2 ~ "Winning politician gloats"),
         treat_prime = case_when(r13pad5_avsender == 1 ~ "Not shown",
                               r13pad5_avsender == 2  | r13pad5_avsender == 5 ~ "No prime",
                               r13pad5_avsender == 3  | r13pad5_avsender == 6 ~ "Specific prime",
                               r13pad5_avsender == 4 | r13pad5_avsender == 7 ~ "General prime"),
       treat_messenger = case_when(r13pad5_avsender %in% 3:4 ~ "Political leader",
                                   r13pad5_avsender %in% 6:7 ~ "Local newspaper"),
                post_fair = case_when(r13pad6a == 1 | r13pad6b == 1 ~ 5,
                          r13pad6a == 2 | r13pad6b == 2 ~ 4,
                          r13pad6a == 3 | r13pad6b == 3 ~ 3,
                          r13pad6a == 4 | r13pad6b == 4 ~ 2,
                          r13pad6a == 5 | r13pad6b == 5 ~ 1),
          post_reasonable = case_when(r13pad7a == 1 | r13pad7b == 1 ~ 5,
                          r13pad7a == 2 | r13pad7b == 2 ~ 4,
                          r13pad7a == 3 | r13pad7b == 3 ~ 3,
                          r13pad7a == 4 | r13pad7b == 4 ~ 2,
                          r13pad7a == 5 | r13pad7b == 5 ~ 1),
          post_accept = case_when(r13pad8a == 1 | r13pad8b == 1 ~ 5,
                          r13pad8a == 2 | r13pad8b == 2 ~ 4,
                          r13pad8a == 3 | r13pad8b == 3 ~ 3,
                          r13pad8a == 4 | r13pad8b == 4 ~ 2,
                          r13pad8a == 5 | r13pad8b == 5 ~ 1)

  ) %>% 
                  replace_with_na_all(condition = ~.x == 98 )%>% #Recode 98 (not asked) as missing
                 filter(!is.na(r13pad6_ran)) %>% 
                mutate(treat_winningmargin = lvls_reorder(treat_winningmargin, c(2, 3, 1)), 
               treat_prime = lvls_reorder(treat_prime, c(3, 2, 4, 1))
                )
               
    main_01 <- main_01 %>%   
      filter(treat_outfav == "Favorable outcome")

7.1.1 Number of winners in the data set

The number of respondents with a favorable decision outcome is 1357

7.2 Reasonable

source("Functions/amce.R")

res_main <-  main_01 %>%
  amce(post_reasonable, treat_winningmargin, treat_winnergloat, treat_prime, treat_messenger) 
  
res_main <- res_main %>% 
  mutate(
  treatment =  case_when(treatment == "treat_outfav" ~ "Outcome\nfavor-\nability",
            treatment == "treat_winningmargin" ~ "Winning\nmargin",
            treatment == "treat_winnergloat" ~ "Winner\ngloats",
            treatment == "treat_prime" ~ "Democratic\nprime",
            treatment == "treat_messenger" ~ "Primer")
)

#Figure
fig_amce <-
  res_main %>%
  ggplot(aes(x = estimate, y = value)) +
  facet_grid(
    treatment ~ .,
    scales = "free_y",
    space = "free_y") +
  geom_errorbarh(
    aes(xmin = estimate - (2 * std_error),
        xmax = estimate + (2 * std_error)),
    height = 0) +
  geom_point() +
  geom_vline(aes(xintercept = 0), linetype = "dotted") +
  scale_x_continuous(
    limits = c(-1, 1),
    breaks = round(seq(-1, 1, .1), 2),
    expand = c(0, 0)) +
   labs(
    x = "Marginal effect, reasonable decision",
    y = "Decision process attributes") +
  theme_bw() +
  theme(plot.margin = unit(c(2, 2, 2, 2), "mm")) +
  theme(panel.spacing = unit(0.5, "lines"))
fig_amce

ggsave(
  here("output", "figs", "pngs", "fig_winners_reasonable.png"),
  plot = fig_amce,
  width = 5.5, height = 2.75
)
## Error in grDevices::png(..., res = dpi, units = "in"): unable to start png() device
#Table
res_main <- res_main %>% 
  select(value, estimate, std_error, statistic, p_value)

kable(res_main, booktabs = TRUE, caption = "Average Marginal Component Effects", col.names = linebreak(c("Treatment value", "Estimate", "Std. Error", "t-statistic", "p value"))) %>%
  kable_styling(bootstrap_options = c("striped", "hover", "responsive")) %>% 
 group_rows(index = c("Winning margin" = 3, "Winner gloating" = 2, "Good loser prime" = 4, "Primer" = 2))
(#tab:post_reasonable_winner)Average Marginal Component Effects
Treatment value Estimate Std. Error t-statistic p value
Winning margin
Not shown 0.0000000 0.0000000 NA NA
Slight majority -0.0028652 0.0627607 -0.0456534 0.9635933
Large majority 0.0538980 0.0610672 0.8826013 0.3776100
Winner gloating
Not shown 0.0000000 0.0000000 NA NA
Winning politician gloats 0.0201640 0.0507234 0.3975275 0.6910418
Good loser prime
Not shown 0.0000000 0.0000000 NA NA
No prime 0.1772243 0.0836907 2.1176097 0.0343920
Specific prime 0.2120333 0.0843903 2.5125310 0.0121036
General prime 0.2770321 0.0833969 3.3218514 0.0009183
Primer
Local newspaper 0.0000000 0.0000000 NA NA
Political leader 0.0338059 0.0646847 0.5226263 0.6013844

7.3 Willingnes to accept

source("Functions/amce.R")

res_main <-  main_01 %>%
  amce(post_accept, treat_winningmargin, treat_winnergloat, treat_prime, treat_messenger) 
  

res_main <- res_main %>% 
  mutate(
  treatment =  case_when(treatment == "treat_outfav" ~ "Outcome\nfavor-\nability",
            treatment == "treat_winningmargin" ~ "Winning\nmargin",
            treatment == "treat_winnergloat" ~ "Winner\ngloats",
            treatment == "treat_prime" ~ "Democratic\nprime",
            treatment == "treat_messenger" ~ "Primer")
)

#Figure
fig_amce <-
  res_main %>%
  ggplot(aes(x = estimate, y = value)) +
  facet_grid(
    treatment ~ .,
    scales = "free_y",
    space = "free_y") +
  geom_errorbarh(
    aes(xmin = estimate - (2 * std_error),
        xmax = estimate + (2 * std_error)),
    height = 0) +
  geom_point() +
  geom_vline(aes(xintercept = 0), linetype = "dotted") +
  scale_x_continuous(
    limits = c(-1, 1),
    breaks = round(seq(-1, 1, .1), 2),
    expand = c(0, 0)) +
   labs(
    x = "Marginal effect, willingnes to accept decision",
    y = "Decision process attributes") +
  theme_bw() +
  theme(plot.margin = unit(c(2, 2, 2, 2), "mm"))
fig_amce

ggsave(
  here("output", "figs", "pngs", "fig_winners_accept.png"),
  plot = fig_amce,
  width = 5.5, height = 2.75
)
## Error in grDevices::png(..., res = dpi, units = "in"): unable to start png() device
#table
res_main <- res_main %>% 
  select(value, estimate, std_error, statistic, p_value)


kable(res_main, booktabs = TRUE, caption = "Average Marginal Component Effects", col.names = linebreak(c("Treatment value", "Estimate", "Std. Error", "t-statistic", "p value"))) %>%
  kable_styling(bootstrap_options = c("striped", "hover", "responsive")) %>% 
 group_rows(index = c("Winning margin" = 3, "Winner gloating" = 2, "Good loser prime" = 4, "Primer" = 2))
(#tab:post_accept_winner)Average Marginal Component Effects
Treatment value Estimate Std. Error t-statistic p value
Winning margin
Not shown 0.0000000 0.0000000 NA NA
Slight majority -0.0290563 0.0602012 -0.4826526 0.6294211
Large majority 0.0538793 0.0586471 0.9187036 0.3584155
Winner gloating
Not shown 0.0000000 0.0000000 NA NA
Winning politician gloats 0.0442801 0.0486976 0.9092867 0.3633617
Good loser prime
Not shown 0.0000000 0.0000000 NA NA
No prime 0.0740720 0.0803623 0.9217250 0.3568376
Specific prime 0.1872033 0.0810659 2.3092712 0.0210797
General prime 0.1811393 0.0801429 2.2602038 0.0239682
Primer
Local newspaper 0.0000000 0.0000000 NA NA
Political leader 0.0194434 0.0598835 0.3246872 0.7455058

7.4 Fairness perceptions

source("Functions/amce.R")

res_main <-  main_01 %>%
  amce(post_fair, treat_winningmargin, treat_winnergloat, treat_prime, treat_messenger) 
  
res_main <- res_main %>% 
  mutate(
  treatment =  case_when(treatment == "treat_outfav" ~ "Outcome\nfavor-\nability",
            treatment == "treat_winningmargin" ~ "Winning\nmargin",
            treatment == "treat_winnergloat" ~ "Winner\ngloats",
            treatment == "treat_prime" ~ "Democratic\nprime",
            treatment == "treat_messenger" ~ "Primer")
)

#Figure
fig_amce <-
  res_main %>%
  ggplot(aes(x = estimate, y = value)) +
  facet_grid(
    treatment ~ .,
    scales = "free_y",
    space = "free_y") +
  geom_errorbarh(
    aes(xmin = estimate - (2 * std_error),
        xmax = estimate + (2 * std_error)),
    height = 0) +
  geom_point() +
  geom_vline(aes(xintercept = 0), linetype = "dotted") +
  scale_x_continuous(
    limits = c(-1, 1),
    breaks = round(seq(-1, 1, .1), 2),
    expand = c(0, 0)) +
   labs(
    x = "Marginal effect, perceived fairness of decision",
    y = "Decision process attributes") +
  theme_bw() +
  theme(plot.margin = unit(c(2, 2, 2, 2), "mm"))
fig_amce

ggsave(
  here("output", "figs", "pngs", "fig_winners_fair.png"),
  plot = fig_amce,
  width = 5.5, height = 2.75
)
## Error in grDevices::png(..., res = dpi, units = "in"): unable to start png() device
#table
res_main <- res_main %>% 
  select(value, estimate, std_error, statistic, p_value)


kable(res_main, booktabs = TRUE, caption = "Average Marginal Component Effects", col.names = linebreak(c("Treatment value", "Estimate", "Std. Error", "t-statistic", "p value"))) %>%
  kable_styling(bootstrap_options = c("striped", "hover", "responsive")) %>% 
 group_rows(index = c("Winning margin" = 3, "Winner gloating" = 2, "Good loser prime" = 4, "Primer" = 2))
(#tab:post_fair_winner)Average Marginal Component Effects
Treatment value Estimate Std. Error t-statistic p value
Winning margin
Not shown 0.0000000 0.0000000 NA NA
Slight majority 0.0197244 0.0590777 0.3338719 0.7385282
Large majority 0.0408602 0.0575201 0.7103645 0.4776012
Winner gloating
Not shown 0.0000000 0.0000000 NA NA
Winning politician gloats 0.0382893 0.0477549 0.8017884 0.4228168
Good loser prime
Not shown 0.0000000 0.0000000 NA NA
No prime 0.2358594 0.0787134 2.9964317 0.0027816
Specific prime 0.2597467 0.0793366 3.2739811 0.0010874
General prime 0.2829616 0.0784072 3.6088719 0.0003188
Primer
Local newspaper 0.0000000 0.0000000 NA NA
Political leader 0.0639957 0.0615041 1.0405108 0.2984272