Preperation of Dataset

#setwd("~/Documents/Dropbox/Research/Eric")
setwd("~/Downloads")

combined2<-read.csv("~/Downloads/all DVs.csv", header=T, sep=",")

#removing empty rows
combined2<-subset(combined2, X.1 !="NA")

combined2 <- subset(combined2, cond != "<NA>")

combined2$bd<-combined2$beta*((1/(1+combined2$delta))^(2/52))*1.5
combined2$bd_not_centered<-combined2$bd
combined2$bd<-combined2$bd-mean(combined2$bd)

#OUTLIER ANALYSIS
hist(combined2$bd)
combined2$outliers[combined2$bd <= (mean(combined2$bd, na.rm = T)-(4*sd(combined2$bd, na.rm=T)))] <- 1
combined2$outliers[combined2$bd > (mean(combined2$bd, na.rm = T)-(4*sd(combined2$bd, na.rm=T)))] <- 0
table(combined2$outliers)
## 
##    0    1 
## 1082    9
combined2 <- subset(combined2, outliers == 0)

combined2$bd_ranked <- ((rank(combined2$bd))/nrow(combined2))*100

b1 <- c(0, 20, 40, 60, 80, 100)
b <- c(0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100)

combined2$quintiles <- .bincode(combined2$bd_ranked, breaks = b1, TRUE, TRUE)
combined2$deciles <- .bincode(combined2$bd_ranked, breaks = b, TRUE, TRUE)

library(ggplot2)

library(plyr)

cdata <- ddply(combined2, c("quintiles", "cond"), summarise,
               N    = length(SS),
               mean = mean(SS),
               sd   = sd(SS),
               ci   = 1.96*(sd / sqrt(N)))

## this is with 95% confidence interval
ggplot(cdata, aes(x=quintiles, y=mean, colour=cond)) + 
    geom_errorbar(aes(ymin=mean-ci, ymax=mean+ci), width=.1) +
    geom_line() +
    geom_point()

## this is with +/- 1 standard deviation

cdata <- ddply(combined2, c("quintiles", "cond"), summarise,
               N    = length(SS),
               mean = mean(SS),
               sd   = sd(SS),
               se   = sd / sqrt(N))

ggplot(cdata, aes(x=quintiles, y=mean, colour=cond)) + 
    geom_errorbar(aes(ymin=mean-se, ymax=mean+se), width=.1) +
    geom_line() +
    geom_point()

cdata1 <- ddply(combined2, c("deciles", "cond"), summarise,
               N    = length(SS),
               mean = mean(SS),
               sd   = sd(SS),
               se   = sd / sqrt(N))

ggplot(cdata1, aes(x=deciles, y=mean, colour=cond)) + 
    geom_errorbar(aes(ymin=mean-se, ymax=mean+se), width=.1) +
    geom_line() +
    geom_point()

#small <- subset(combined2, select = c("cond","quintiles","deciles","SS","aware","directIE","indirectIE","ease","refdep","hong8","hong9","hong11","hong13","self","others","influence","interviewtime.x","believe.x","X.studies","gender","age","income","education","smoking"))

#write.csv(x = small, file = "WGN_complete_Dec7_2017.csv")

Contrast Analysis

library(MASS)

combined2$cond_contrast <- as.character(combined2$cond)

combined2$cond_contrast[combined2$cond_contrast == "no"] <- 0
combined2$cond_contrast[combined2$cond_contrast == "SS"] <- -1
combined2$cond_contrast[combined2$cond_contrast == "LL"] <- 1

combined2$cond_contrast <- as.factor(combined2$cond_contrast)

combined2$quint_f <- as.factor(combined2$quintiles)

## Without Control Variables

summary(m1 <- aov(SS ~ cond_contrast * quint_f, combined2))
##                         Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast            2   1.72   0.861   3.863 0.0213 *  
## quint_f                  4  27.66   6.916  31.017 <2e-16 ***
## cond_contrast:quint_f    8   2.93   0.366   1.640 0.1092    
## Residuals             1067 237.92   0.223                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## With Control Variables

summary(m1 <- aov(SS ~ cond_contrast * quint_f + gender + age + income + education + X.studies, combined2))
##                        Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast           2   1.19   0.597   2.666 0.0701 .  
## quint_f                 4  23.33   5.832  26.055 <2e-16 ***
## gender                  2   0.25   0.126   0.562 0.5703    
## age                     1   0.17   0.165   0.738 0.3905    
## income                 13   2.48   0.191   0.853 0.6030    
## education               8   1.79   0.223   0.997 0.4369    
## X.studies               1   0.32   0.320   1.429 0.2322    
## cond_contrast:quint_f   8   3.16   0.395   1.766 0.0802 .  
## Residuals             869 194.53   0.224                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 173 observations deleted due to missingness
## Analyses per quintile

summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(combined2, quintiles == 1)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 1))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.8867  -1.3308   0.6078   0.7502   1.0314  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)    
## (Intercept)      1.5950     0.2931   5.442 5.28e-08 ***
## cond_contrast0  -0.4711     0.4334  -1.087 0.277034    
## cond_contrast1  -1.2414     0.3708  -3.348 0.000814 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 255.24  on 215  degrees of freedom
## Residual deviance: 242.82  on 213  degrees of freedom
## AIC: 248.82
## 
## Number of Fisher Scoring iterations: 4
#Here is the NO DEFAULT vs. LL contrast that Crystal requested. 

LLcontrol<-subset(combined2, cond!="SS")
summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(LLcontrol, quintiles == 1)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(LLcontrol, quintiles == 1))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.6765  -1.3308   0.7502   1.0314   1.0314  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)    
## (Intercept)      1.1239     0.3193   3.520 0.000431 ***
## cond_contrast1  -0.7703     0.3918  -1.966 0.049292 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 171.53  on 132  degrees of freedom
## Residual deviance: 167.49  on 131  degrees of freedom
## AIC: 171.49
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(combined2, quintiles == 2)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 2))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.4181  -1.1681   0.9544   0.9647   1.1868  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)  
## (Intercept)      0.5501     0.2293   2.399   0.0164 *
## cond_contrast0  -0.0268     0.3900  -0.069   0.9452  
## cond_contrast1  -0.5720     0.3107  -1.841   0.0656 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 294.68  on 215  degrees of freedom
## Residual deviance: 290.61  on 213  degrees of freedom
## AIC: 296.61
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(combined2, quintiles == 3)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 3))
## 
## Deviance Residuals: 
##    Min      1Q  Median      3Q     Max  
## -1.239  -1.219   1.117   1.136   1.254  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)
## (Intercept)     0.09764    0.22113   0.442    0.659
## cond_contrast0  0.04546    0.34741   0.131    0.896
## cond_contrast1 -0.27532    0.31612  -0.871    0.384
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 300.82  on 216  degrees of freedom
## Residual deviance: 299.72  on 214  degrees of freedom
## AIC: 305.72
## 
## Number of Fisher Scoring iterations: 3
summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(combined2, quintiles == 4)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 4))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.9956  -0.9005  -0.9005   1.3708   1.4823  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)  
## (Intercept)     -0.4439     0.2197   -2.02   0.0433 *
## cond_contrast0  -0.2492     0.3369   -0.74   0.4595  
## cond_contrast1  -0.2492     0.3511   -0.71   0.4778  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 281.39  on 215  degrees of freedom
## Residual deviance: 280.65  on 213  degrees of freedom
## AIC: 286.65
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast, family = binomial(link = "logit"), data = subset(combined2, quintiles == 5)))
## 
## Call:
## glm(formula = SS ~ cond_contrast, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 5))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.9080  -0.7518  -0.7012   1.4732   1.7456  
## 
## Coefficients:
##                Estimate Std. Error z value Pr(>|z|)    
## (Intercept)     -1.1192     0.2879  -3.887 0.000101 ***
## cond_contrast0  -0.1584     0.3976  -0.398 0.690325    
## cond_contrast1   0.4463     0.3786   1.179 0.238449    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 251.95  on 216  degrees of freedom
## Residual deviance: 249.00  on 214  degrees of freedom
## AIC: 255
## 
## Number of Fisher Scoring iterations: 4
## Dropping control condition

combined2$cond_contrast2 <- as.character(combined2$cond)

combined2$cond_contrast2[combined2$cond_contrast2 == "no"] <- NA
combined2$cond_contrast2[combined2$cond_contrast2 == "SS"] <- "SS"
combined2$cond_contrast2[combined2$cond_contrast2 == "LL"] <- "LL"

combined2$cond_contrast <- as.factor(combined2$cond_contrast)

summary(m1 <- aov(SS ~ cond_contrast2*quint_f, combined2))
##                         Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast2           1   1.44   1.441   6.348   0.0120 *  
## quint_f                  4  16.51   4.127  18.178 2.78e-14 ***
## cond_contrast2:quint_f   4   2.27   0.567   2.498   0.0415 *  
## Residuals              773 175.51   0.227                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 299 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast2*quint_f + gender + age + income + education + X.studies, combined2))
##                         Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast2           1   0.67  0.6715   2.911   0.0885 .  
## quint_f                  4  12.17  3.0424  13.187 2.75e-10 ***
## gender                   2   0.18  0.0906   0.393   0.6754    
## age                      1   0.24  0.2413   1.046   0.3069    
## income                  13   2.58  0.1985   0.860   0.5956    
## education                8   1.34  0.1669   0.723   0.6710    
## X.studies                1   0.48  0.4786   2.074   0.1503    
## cond_contrast2:quint_f   4   2.17  0.5423   2.350   0.0531 .  
## Residuals              578 133.35  0.2307                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 469 observations deleted due to missingness
summary(glm(SS ~ cond_contrast2, family = binomial(link = "logit"), data = subset(combined2, quintiles == 1)))
## 
## Call:
## glm(formula = SS ~ cond_contrast2, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 1))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.8867  -1.3308   0.6078   1.0314   1.0314  
## 
## Coefficients:
##                  Estimate Std. Error z value Pr(>|z|)    
## (Intercept)        0.3536     0.2271   1.557 0.119442    
## cond_contrast2SS   1.2414     0.3708   3.348 0.000814 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 195.82  on 162  degrees of freedom
## Residual deviance: 183.77  on 161  degrees of freedom
##   (53 observations deleted due to missingness)
## AIC: 187.77
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast2, family = binomial(link = "logit"), data = subset(combined2, quintiles == 2)))
## 
## Call:
## glm(formula = SS ~ cond_contrast2, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 2))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.4181  -1.1681   0.9544   1.1868   1.1868  
## 
## Coefficients:
##                  Estimate Std. Error z value Pr(>|z|)  
## (Intercept)      -0.02198    0.20967  -0.105   0.9165  
## cond_contrast2SS  0.57203    0.31069   1.841   0.0656 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 237.27  on 172  degrees of freedom
## Residual deviance: 233.84  on 171  degrees of freedom
##   (43 observations deleted due to missingness)
## AIC: 237.84
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast2, family = binomial(link = "logit"), data = subset(combined2, quintiles == 3)))
## 
## Call:
## glm(formula = SS ~ cond_contrast2, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 3))
## 
## Deviance Residuals: 
##    Min      1Q  Median      3Q     Max  
## -1.219  -1.103  -1.103   1.136   1.254  
## 
## Coefficients:
##                  Estimate Std. Error z value Pr(>|z|)
## (Intercept)       -0.1777     0.2259  -0.787    0.432
## cond_contrast2SS   0.2753     0.3161   0.871    0.384
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 223.14  on 160  degrees of freedom
## Residual deviance: 222.38  on 159  degrees of freedom
##   (56 observations deleted due to missingness)
## AIC: 226.38
## 
## Number of Fisher Scoring iterations: 3
summary(glm(SS ~ cond_contrast2, family = binomial(link = "logit"), data = subset(combined2, quintiles == 4)))
## 
## Call:
## glm(formula = SS ~ cond_contrast2, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 4))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.9956  -0.9956  -0.9005   1.3708   1.4823  
## 
## Coefficients:
##                  Estimate Std. Error z value Pr(>|z|)  
## (Intercept)       -0.6931     0.2739  -2.531   0.0114 *
## cond_contrast2SS   0.2492     0.3511   0.710   0.4778  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 193.31  on 146  degrees of freedom
## Residual deviance: 192.81  on 145  degrees of freedom
##   (69 observations deleted due to missingness)
## AIC: 196.81
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ cond_contrast2, family = binomial(link = "logit"), data = subset(combined2, quintiles == 5)))
## 
## Call:
## glm(formula = SS ~ cond_contrast2, family = binomial(link = "logit"), 
##     data = subset(combined2, quintiles == 5))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.9080  -0.9080  -0.7518   1.4732   1.6744  
## 
## Coefficients:
##                  Estimate Std. Error z value Pr(>|z|)   
## (Intercept)       -0.6729     0.2458  -2.738  0.00618 **
## cond_contrast2SS  -0.4463     0.3786  -1.179  0.23845   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 168.62  on 138  degrees of freedom
## Residual deviance: 167.21  on 137  degrees of freedom
##   (78 observations deleted due to missingness)
## AIC: 171.21
## 
## Number of Fisher Scoring iterations: 4
## If we want to report deciles...

summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 1)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 1))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -2.0393   0.0767   0.5350   0.5350   1.1127  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)   
## (Intercept)         0.1542     0.3212   0.480  0.63129   
## as.factor(cond)no   1.7918     0.6958   2.575  0.01002 * 
## as.factor(cond)SS   1.7177     0.5436   3.160  0.00158 **
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 121.46  on 107  degrees of freedom
## Residual deviance: 107.26  on 105  degrees of freedom
## AIC: 113.26
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 2)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 2))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.7653  -1.4181   0.6876   0.9196   0.9544  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)  
## (Intercept)        0.55005    0.32423   1.696   0.0898 .
## as.factor(cond)no  0.09181    0.50770   0.181   0.8565  
## as.factor(cond)SS  0.77171    0.51328   1.503   0.1327  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 132.95  on 107  degrees of freedom
## Residual deviance: 130.33  on 105  degrees of freedom
## AIC: 136.33
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 3)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 3))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.5315  -1.0323   0.8607   0.9282   1.3298  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)  
## (Intercept)        -0.3514     0.2994  -1.173   0.2406  
## as.factor(cond)no   0.9704     0.5563   1.745   0.0811 .
## as.factor(cond)SS   1.1537     0.4484   2.573   0.0101 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 147.90  on 107  degrees of freedom
## Residual deviance: 140.24  on 105  degrees of freedom
## AIC: 146.24
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 4)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 4))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.3699  -1.3132   0.9964   1.0474   1.0520  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)
## (Intercept)        0.31366    0.30182   1.039    0.299
## as.factor(cond)no  0.12818    0.52310   0.245    0.806
## as.factor(cond)SS -0.01138    0.43977  -0.026    0.979
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 146.71  on 107  degrees of freedom
## Residual deviance: 146.63  on 105  degrees of freedom
## AIC: 152.63
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 5)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 5))
## 
## Deviance Residuals: 
##    Min      1Q  Median      3Q     Max  
## -1.354  -1.145   1.011   1.081   1.210  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)
## (Intercept)       -0.07696    0.27756  -0.277    0.782
## as.factor(cond)no  0.48243    0.95407   0.506    0.613
## as.factor(cond)SS  0.30876    0.39370   0.784    0.433
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 150.88  on 108  degrees of freedom
## Residual deviance: 150.13  on 106  degrees of freedom
## AIC: 156.13
## 
## Number of Fisher Scoring iterations: 3
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 6)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 6))
## 
## Deviance Residuals: 
##    Min      1Q  Median      3Q     Max  
## -1.228  -1.121  -1.023   1.128   1.340  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)
## (Intercept)        -0.3747     0.3917  -0.957    0.339
## as.factor(cond)no   0.4925     0.4818   1.022    0.307
## as.factor(cond)SS   0.2412     0.5360   0.450    0.653
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 149.57  on 107  degrees of freedom
## Residual deviance: 148.48  on 105  degrees of freedom
## AIC: 154.48
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 7)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 7))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.2163  -0.9508  -0.8826   1.1390   1.5043  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)  
## (Intercept)        -0.7419     0.3842  -1.931   0.0535 .
## as.factor(cond)no   0.1823     0.5278   0.345   0.7298  
## as.factor(cond)SS   0.8329     0.4886   1.705   0.0882 .
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 146.71  on 107  degrees of freedom
## Residual deviance: 143.15  on 105  degrees of freedom
## AIC: 149.15
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 8)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 8))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.9196  -0.8540  -0.7687   1.4592   1.6512  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)
## (Intercept)        -0.6419     0.3907  -1.643    0.100
## as.factor(cond)no  -0.1791     0.5325  -0.336    0.737
## as.factor(cond)SS  -0.4260     0.5242  -0.813    0.416
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 131.26  on 107  degrees of freedom
## Residual deviance: 130.58  on 105  degrees of freedom
## AIC: 136.58
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 9)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 9))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -0.8620  -0.7585  -0.7276   1.5297   1.7080  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)   
## (Intercept)       -1.09861    0.38490  -2.854  0.00431 **
## as.factor(cond)no -0.09531    0.52768  -0.181  0.85667   
## as.factor(cond)SS  0.30010    0.55611   0.540  0.58944   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 123.61  on 107  degrees of freedom
## Residual deviance: 123.05  on 105  degrees of freedom
## AIC: 129.05
## 
## Number of Fisher Scoring iterations: 4
summary(glm(SS ~ as.factor(cond), family = binomial(link = "logit"), data = subset(combined2, deciles == 10)))
## 
## Call:
## glm(formula = SS ~ as.factor(cond), family = binomial(link = "logit"), 
##     data = subset(combined2, deciles == 10))
## 
## Deviance Residuals: 
##     Min       1Q   Median       3Q      Max  
## -1.0455  -0.6681  -0.6576   1.3153   1.8098  
## 
## Coefficients:
##                   Estimate Std. Error z value Pr(>|z|)  
## (Intercept)        -0.3185     0.3286  -0.969   0.3324  
## as.factor(cond)no  -1.0678     0.5353  -1.995   0.0461 *
## as.factor(cond)SS  -1.1029     0.5341  -2.065   0.0389 *
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## (Dispersion parameter for binomial family taken to be 1)
## 
##     Null deviance: 128.27  on 108  degrees of freedom
## Residual deviance: 122.22  on 106  degrees of freedom
## AIC: 128.22
## 
## Number of Fisher Scoring iterations: 4

Moderator Analyses

summary(m1 <- aov(SS ~ cond_contrast * quint_f, combined2))
##                         Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast            2   1.72   0.861   3.863 0.0213 *  
## quint_f                  4  27.66   6.916  31.017 <2e-16 ***
## cond_contrast:quint_f    8   2.93   0.366   1.640 0.1092    
## Residuals             1067 237.92   0.223                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(m1 <- aov(SS ~ cond_contrast * quint_f * aware, combined2))
##                              Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast                 2   1.20   0.599   2.858 0.0582 .  
## quint_f                       4  22.43   5.607  26.747 <2e-16 ***
## aware                         1   0.05   0.047   0.226 0.6343    
## cond_contrast:quint_f         8   2.12   0.264   1.261 0.2612    
## cond_contrast:aware           2   0.26   0.131   0.626 0.5350    
## quint_f:aware                 4   0.44   0.111   0.530 0.7137    
## cond_contrast:quint_f:aware   6   2.45   0.408   1.948 0.0712 .  
## Residuals                   578 121.17   0.210                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f * directIE, combined2))
##                                 Df Sum Sq Mean Sq F value  Pr(>F)    
## cond_contrast                    2   1.20   0.599   2.959 0.05266 .  
## quint_f                          4  22.43   5.607  27.693 < 2e-16 ***
## directIE                         1   1.28   1.279   6.317 0.01223 *  
## cond_contrast:quint_f            8   2.16   0.271   1.337 0.22237    
## cond_contrast:directIE           2   1.49   0.746   3.682 0.02576 *  
## quint_f:directIE                 4   2.93   0.732   3.615 0.00638 ** 
## cond_contrast:quint_f:directIE   8   2.00   0.250   1.237 0.27482    
## Residuals                      576 116.62   0.202                    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f * indirectIE, combined2))
##                                   Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast                      2   1.20   0.599   2.828 0.0599 .  
## quint_f                            4  22.43   5.607  26.470 <2e-16 ***
## indirectIE                         1   0.75   0.753   3.554 0.0599 .  
## cond_contrast:quint_f              8   2.07   0.259   1.222 0.2834    
## cond_contrast:indirectIE           2   0.45   0.226   1.068 0.3442    
## quint_f:indirectIE                 4   0.30   0.076   0.356 0.8396    
## cond_contrast:quint_f:indirectIE   8   0.90   0.113   0.532 0.8326    
## Residuals                        576 122.01   0.212                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f * ease, combined2))
##                             Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast                2   1.20   0.599   2.925   0.0544 .  
## quint_f                      4  22.43   5.607  27.378  < 2e-16 ***
## ease                         1   4.51   4.511  22.026 3.36e-06 ***
## cond_contrast:quint_f        8   1.78   0.223   1.087   0.3702    
## cond_contrast:ease           2   0.75   0.374   1.826   0.1621    
## quint_f:ease                 4   0.41   0.104   0.506   0.7315    
## cond_contrast:quint_f:ease   8   1.07   0.134   0.652   0.7338    
## Residuals                  576 117.96   0.205                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f * refdep, combined2))
##                               Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast                  2   1.20   0.599   3.055   0.0479 *  
## quint_f                        4  22.43   5.607  28.588  < 2e-16 ***
## refdep                         1   3.45   3.450  17.590 3.17e-05 ***
## cond_contrast:quint_f          8   1.94   0.243   1.237   0.2747    
## cond_contrast:refdep           2   4.63   2.313  11.793 9.56e-06 ***
## quint_f:refdep                 4   1.61   0.403   2.055   0.0853 .  
## cond_contrast:quint_f:refdep   8   1.89   0.236   1.202   0.2951    
## Residuals                    576 112.97   0.196                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f + aware, combined2))
##                        Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast           2   1.20   0.599   2.843  0.059 .  
## quint_f                 4  22.43   5.607  26.608 <2e-16 ***
## aware                   1   0.05   0.047   0.225  0.635    
## cond_contrast:quint_f   8   2.12   0.264   1.255  0.265    
## Residuals             590 124.32   0.211                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f + directIE, combined2))
##                        Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast           2   1.20   0.599   2.873 0.0573 .  
## quint_f                 4  22.43   5.607  26.886 <2e-16 ***
## directIE                1   1.28   1.279   6.133 0.0135 *  
## cond_contrast:quint_f   8   2.16   0.271   1.298 0.2418    
## Residuals             590 123.04   0.209                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f + indirectIE, combined2))
##                        Df Sum Sq Mean Sq F value Pr(>F)    
## cond_contrast           2   1.20   0.599   2.858 0.0582 .  
## quint_f                 4  22.43   5.607  26.751 <2e-16 ***
## indirectIE              1   0.75   0.753   3.591 0.0586 .  
## cond_contrast:quint_f   8   2.07   0.259   1.235 0.2759    
## Residuals             590 123.66   0.210                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f + ease, combined2))
##                        Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast           2   1.20   0.599   2.941   0.0536 .  
## quint_f                 4  22.43   5.607  27.523  < 2e-16 ***
## ease                    1   4.51   4.511  22.143 3.16e-06 ***
## cond_contrast:quint_f   8   1.78   0.223   1.093   0.3661    
## Residuals             590 120.19   0.204                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness
summary(m1 <- aov(SS ~ cond_contrast * quint_f + refdep, combined2))
##                        Df Sum Sq Mean Sq F value   Pr(>F)    
## cond_contrast           2   1.20   0.599   2.919   0.0548 .  
## quint_f                 4  22.43   5.607  27.318  < 2e-16 ***
## refdep                  1   3.45   3.450  16.809 4.71e-05 ***
## cond_contrast:quint_f   8   1.94   0.243   1.182   0.3074    
## Residuals             590 121.10   0.205                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 476 observations deleted due to missingness

Creating attention check variable to use for excluding people who failed.

#recoding "reader" into attention check failure/success 
combined2$attn[combined2$reader == "reader" | combined2$reader == "Reader"|combined2$reader == "READER"|combined2$reader== " reader"|combined2$reader== "reader " | combined2$reader== "readers" ]<-1

combined2$attn[combined2$reader != "reader" & combined2$reader != "Reader"& combined2$reader != "READER" & combined2$reader!= " reader"&combined2$reader!= "reader " & combined2$reader!= "readers" ]<-0

table(combined2$attn)
## 
##   0   1 
## 277 805
pass<-subset(combined2, attn==1)

Looking at ease, implied endorsement, reference dependence, and belief about the default’s effects (although only half the sample has this data)

#WITH CONTROL CONDITION 
summary(lm(ease ~ cond*bd, combined2))
## 
## Call:
## lm(formula = ease ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -2.1339 -1.0458 -0.3833  0.9678  3.3121 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  2.06195    0.09489  21.731   <2e-16 ***
## condno       0.18080    0.13489   1.340    0.181    
## condSS       0.07132    0.13072   0.546    0.586    
## bd          -0.70460    0.45220  -1.558    0.120    
## condno:bd   -0.61714    0.68110  -0.906    0.365    
## condSS:bd   -0.53135    0.60439  -0.879    0.380    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.318 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.03194,    Adjusted R-squared:  0.02387 
## F-statistic: 3.959 on 5 and 600 DF,  p-value: 0.001533
summary(lm(refdep ~ cond*bd, combined2))
## 
## Call:
## lm(formula = refdep ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -2.1082 -0.7918 -0.5459  0.4564  3.4353 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.86504    0.08434  22.113   <2e-16 ***
## condno      -0.23905    0.11990  -1.994   0.0466 *  
## condSS       0.06748    0.11619   0.581   0.5616    
## bd           0.41307    0.40195   1.028   0.3045    
## condno:bd   -1.12903    0.60541  -1.865   0.0627 .  
## condSS:bd   -2.22311    0.53722  -4.138    4e-05 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.172 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.06058,    Adjusted R-squared:  0.05275 
## F-statistic: 7.739 on 5 and 600 DF,  p-value: 4.56e-07
summary(lm(directIE ~ cond*bd, combined2))
## 
## Call:
## lm(formula = directIE ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.8643 -0.5696 -0.3877  0.3976  3.6452 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.63078    0.06389  25.526   <2e-16 ***
## condno      -0.19000    0.09082  -2.092   0.0369 *  
## condSS      -0.08694    0.08801  -0.988   0.3236    
## bd          -0.12989    0.30447  -0.427   0.6698    
## condno:bd   -0.52075    0.45859  -1.136   0.2566    
## condSS:bd   -0.13559    0.40694  -0.333   0.7391    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.8876 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.01711,    Adjusted R-squared:  0.008921 
## F-statistic: 2.089 on 5 and 600 DF,  p-value: 0.06511
summary(lm(indirectIE ~ cond*bd, combined2))
## 
## Call:
## lm(formula = indirectIE ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.9902 -0.6504 -0.5308  0.3852  3.3670 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.61746    0.07043  22.965   <2e-16 ***
## condno      -0.02724    0.10012  -0.272    0.786    
## condSS       0.08916    0.09703   0.919    0.358    
## bd           0.07434    0.33566   0.221    0.825    
## condno:bd   -0.78401    0.50557  -1.551    0.121    
## condSS:bd   -0.34350    0.44863  -0.766    0.444    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.9786 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.01097,    Adjusted R-squared:  0.002729 
## F-statistic: 1.331 on 5 and 600 DF,  p-value: 0.2492
summary(lm(self ~ cond*bd, combined2))
## 
## Call:
## lm(formula = self ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.7872 -0.4159 -0.2480 -0.1982  3.7596 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.48091    0.05511  26.872  < 2e-16 ***
## condno      -0.26908    0.07834  -3.435 0.000634 ***
## condSS      -0.11851    0.07592  -1.561 0.119062    
## bd          -0.45309    0.26264  -1.725 0.085025 .  
## condno:bd    0.35456    0.39559   0.896 0.370462    
## condSS:bd    0.15655    0.35104   0.446 0.655780    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.7657 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.02698,    Adjusted R-squared:  0.01887 
## F-statistic: 3.327 on 5 and 600 DF,  p-value: 0.005673
summary(lm(others ~ cond*bd, combined2))
## 
## Call:
## lm(formula = others ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -1.8221 -0.6651  0.2957  0.4157  2.4744 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  2.65317    0.06405  41.425   <2e-16 ***
## condno      -0.22370    0.09105  -2.457   0.0143 *  
## condSS       0.04918    0.08823   0.557   0.5774    
## bd          -0.24983    0.30524  -0.818   0.4134    
## condno:bd    1.37959    0.45974   3.001   0.0028 ** 
## condSS:bd    0.27369    0.40796   0.671   0.5026    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.8899 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.03055,    Adjusted R-squared:  0.02247 
## F-statistic: 3.781 on 5 and 600 DF,  p-value: 0.002224
summary(lm(influence ~ cond*bd, combined2))
## 
## Call:
## lm(formula = influence ~ cond * bd, data = combined2)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.8884 -0.4544 -0.3038  0.4390  3.6042 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.54408    0.05747  26.866  < 2e-16 ***
## condno      -0.22923    0.08170  -2.806  0.00518 ** 
## condSS      -0.15422    0.07918  -1.948  0.05191 .  
## bd          -0.19252    0.27390  -0.703  0.48240    
## condno:bd    0.05451    0.41255   0.132  0.89493    
## condSS:bd   -0.44831    0.36608  -1.225  0.22120    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.7985 on 600 degrees of freedom
##   (476 observations deleted due to missingness)
## Multiple R-squared:  0.02617,    Adjusted R-squared:  0.01806 
## F-statistic: 3.225 on 5 and 600 DF,  p-value: 0.006979
#WITHOUT CONTROL CONDITION 
nocontrol<-subset(combined2, cond!="no")

summary(lm(ease ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = ease ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -2.1339 -1.0043 -0.4741  0.9714  3.3121 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  2.06195    0.09515  21.670   <2e-16 ***
## condSS       0.07132    0.13108   0.544    0.587    
## bd          -0.70460    0.45347  -1.554    0.121    
## condSS:bd   -0.53135    0.60608  -0.877    0.381    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.322 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.0294, Adjusted R-squared:  0.02221 
## F-statistic: 4.089 on 3 and 405 DF,  p-value: 0.007051
summary(lm(refdep ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = refdep ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -2.1082 -0.8981 -0.6879  0.4558  3.3049 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.86504    0.09104  20.486  < 2e-16 ***
## condSS       0.06748    0.12542   0.538 0.590875    
## bd           0.41307    0.43388   0.952 0.341643    
## condSS:bd   -2.22311    0.57990  -3.834 0.000146 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.265 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.0544, Adjusted R-squared:  0.04739 
## F-statistic: 7.766 on 3 and 405 DF,  p-value: 4.709e-05
summary(lm(directIE ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = directIE ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.7566 -0.6134 -0.5202  0.3979  3.4922 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.63078    0.06494  25.112   <2e-16 ***
## condSS      -0.08694    0.08946  -0.972    0.332    
## bd          -0.12989    0.30949  -0.420    0.675    
## condSS:bd   -0.13559    0.41364  -0.328    0.743    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.9023 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.004939,   Adjusted R-squared:  -0.002432 
## F-statistic: 0.6701 on 3 and 405 DF,  p-value: 0.5708
summary(lm(indirectIE ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = indirectIE ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.9223 -0.6711 -0.6149  0.3761  3.3670 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.61746    0.07237  22.349   <2e-16 ***
## condSS       0.08916    0.09970   0.894    0.372    
## bd           0.07434    0.34490   0.216    0.829    
## condSS:bd   -0.34350    0.46098  -0.745    0.457    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 1.006 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.003958,   Adjusted R-squared:  -0.00342 
## F-statistic: 0.5365 on 3 and 405 DF,  p-value: 0.6575
summary(lm(self ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = self ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.7872 -0.4409 -0.3647  0.3988  3.7596 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.48091    0.06020  24.598   <2e-16 ***
## condSS      -0.11851    0.08294  -1.429    0.154    
## bd          -0.45309    0.28692  -1.579    0.115    
## condSS:bd    0.15655    0.38348   0.408    0.683    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.8365 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.01379,    Adjusted R-squared:  0.006482 
## F-statistic: 1.887 on 3 and 405 DF,  p-value: 0.1311
summary(lm(others ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = others ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -1.8221 -0.6960  0.2956  0.3677  2.4039 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  2.65317    0.06383  41.563   <2e-16 ***
## condSS       0.04918    0.08794   0.559    0.576    
## bd          -0.24983    0.30422  -0.821    0.412    
## condSS:bd    0.27369    0.40660   0.673    0.501    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.8869 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.002572,   Adjusted R-squared:  -0.004817 
## F-statistic: 0.3481 on 3 and 405 DF,  p-value: 0.7906
summary(lm(influence ~ cond*bd, nocontrol))
## 
## Call:
## lm(formula = influence ~ cond * bd, data = nocontrol)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -0.8884 -0.5194 -0.3366  0.4486  3.6042 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1.54408    0.06097  25.326   <2e-16 ***
## condSS      -0.15422    0.08399  -1.836   0.0671 .  
## bd          -0.19252    0.29055  -0.663   0.5080    
## condSS:bd   -0.44831    0.38834  -1.154   0.2490    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.8471 on 405 degrees of freedom
##   (374 observations deleted due to missingness)
## Multiple R-squared:  0.02373,    Adjusted R-squared:  0.0165 
## F-statistic: 3.282 on 3 and 405 DF,  p-value: 0.02091
#ALSO CONFIRMING THAT PEOPLE IN THE CONTROL CONDITION ANSWERED THESE QUESTIONS, AND THE REACTANCE QUESTIONS
control<-subset(combined2, cond=="no")

summary(control$hong11)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
##   1.000   3.000   3.000   3.239   4.000   5.000     102
summary(control$refdep)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
##   1.000   1.000   1.000   1.599   2.000   5.000     102
summary(control$ease)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
##   1.000   1.000   2.000   2.193   3.000   5.000     102
combined2$reactance <- (combined2$hong8+combined2$hong9+combined2$hong11+combined2$hong13)/4
summary(combined2$reactance)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max.    NA's 
##   1.000   1.750   2.000   2.091   2.500   4.250     476

Demographic analyses

table(combined2$education)
## 
##                                                            
##                                                          0 
##                                    9th, 10th or 11th grade 
##                                                          5 
##                     Associate degree (for example: AA, AS) 
##                                                        113 
##                Bachelor's degree (for example: BA, AB, BS) 
##                                                        422 
##                   Doctorate degree (for example: PhD, EdD) 
##                                                         12 
##   High school diploma or the equivalent (for example: GED) 
##                                                         97 
## Master's degree (for example: MA, MS, MEng, MEd, MSW, MBA) 
##                                                         92 
##   Professional degree (for example: MD, DDS, DVM, LLB, JD) 
##                                                         14 
##                       Some college, and currently enrolled 
##                                                         98 
##                   Some college, but not currently enrolled 
##                                                        229
combined2$edu[combined2$education=="9th, 10th or 11th grade"]<-1
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "9th, 10th or 11th
## grade", : invalid factor level, NA generated
combined2$edu[combined2$education=="High school diploma or the equivalent (for example: GED)"]<-2
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "High school
## diploma or the equivalent (for example: GED)", : invalid factor level, NA
## generated
combined2$edu[combined2$education=="Associate degree (for example: AA, AS)"]<-3
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Associate degree
## (for example: AA, AS)", : invalid factor level, NA generated
combined2$edu[combined2$education=="Some college, but not currently enrolled"]<-4
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Some college, but
## not currently enrolled", : invalid factor level, NA generated
combined2$edu[combined2$education=="Some college, and currently enrolled"]<-5
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Some college, and
## currently enrolled", : invalid factor level, NA generated
combined2$edu[combined2$education=="Bachelor's degree (for example: BA, AB, BS)"]<-6
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Bachelor's degree
## (for example: BA, AB, BS)", : invalid factor level, NA generated
combined2$edu[combined2$education=="Professional degree (for example: MD, DDS, DVM, LLB, JD)"]<-6
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Professional
## degree (for example: MD, DDS, DVM, LLB, JD)", : invalid factor level, NA
## generated
combined2$edu[combined2$education=="Master's degree (for example: MA, MS, MEng, MEd, MSW, MBA)"]<-7
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Master's degree
## (for example: MA, MS, MEng, MEd, MSW, MBA)", : invalid factor level, NA
## generated
combined2$edu[combined2$education=="Doctorate degree (for example: PhD, EdD)"]<-8
## Warning in `[<-.factor`(`*tmp*`, combined2$education == "Doctorate degree
## (for example: PhD, EdD)", : invalid factor level, NA generated
combined2$edu<-as.numeric(combined2$edu)

combined2$edu[combined2$education=="9th, 10th or 11th grade"]<-1
combined2$edu[combined2$education=="High school diploma or the equivalent (for example: GED)"]<-2
combined2$edu[combined2$education=="Associate degree (for example: AA, AS)"]<-3
combined2$edu[combined2$education=="Some college, but not currently enrolled"]<-4
combined2$edu[combined2$education=="Some college, and currently enrolled"]<-5
combined2$edu[combined2$education=="Bachelor's degree (for example: BA, AB, BS)"]<-6
combined2$edu[combined2$education=="Professional degree (for example: MD, DDS, DVM, LLB, JD)"]<-6
combined2$edu[combined2$education=="Master's degree (for example: MA, MS, MEng, MEd, MSW, MBA)"]<-7
combined2$edu[combined2$education=="Doctorate degree (for example: PhD, EdD)"]<-8

table(combined2$edu)
## 
##   1   2   3   4   5   6   7   8 
##   5  97 113 229  98 436  92  12
#centering
summary(combined2$edu)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   1.000   4.000   5.000   4.898   6.000   8.000
combined2$eduCentered<-combined2$edu - 4.889
summary(combined2$eduCentered)
##      Min.   1st Qu.    Median      Mean   3rd Qu.      Max. 
## -3.889000 -0.889000  0.111000  0.009336  1.111000  3.111000
#re-coding income as numeric
table(combined2$income)
## 
##                        $10,000 to $19,999 $100,000 to $124,999 
##                    0                  105                   69 
## $125,000 to $149,999 $150,000 to $199,999   $20,000 to $29,999 
##                   36                   24                  133 
##     $200,000 or more   $30,000 to $39,999   $40,000 to $49,999 
##                   12                  145                  132 
##   $50,000 to $59,999   $60,000 to $69,999   $70,000 to $79,999 
##                  102                   85                   65 
##   $80,000 to $89,999   $90,000 to $99,999    Less than $10,000 
##                   52                   41                   81
combined2$inc[combined2$income=="Less than $10,000"]<-1
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "Less than $10,000", :
## invalid factor level, NA generated
combined2$inc[combined2$income=="$10,000 to $19,999"]<-2
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$10,000 to
## $19,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$20,000 to $29,999"]<-3
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$20,000 to
## $29,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$30,000 to $39,999"]<-4
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$30,000 to
## $39,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$40,000 to $49,999"]<-5
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$40,000 to
## $49,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$50,000 to $59,999"]<-6
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$50,000 to
## $59,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$60,000 to $69,999"]<-7
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$60,000 to
## $69,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$70,000 to $79,999"]<-8
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$70,000 to
## $79,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$80,000 to $89,999"]<-9
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$80,000 to
## $89,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$90,000 to $99,999"]<-10
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$90,000 to
## $99,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$100,000 to $124,999"]<-11
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$100,000 to
## $124,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="$150,000 to $199,999"]<-12
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "$150,000 to
## $199,999", : invalid factor level, NA generated
combined2$inc[combined2$income=="200,000 or more"]<-13
## Warning in `[<-.factor`(`*tmp*`, combined2$income == "200,000 or more", :
## invalid factor level, NA generated
combined2$inc<-as.numeric(combined2$inc)

combined2$inc[combined2$income=="Less than $10,000"]<-1
combined2$inc[combined2$income=="$10,000 to $19,999"]<-2
combined2$inc[combined2$income=="$20,000 to $29,999"]<-3
combined2$inc[combined2$income=="$30,000 to $39,999"]<-4
combined2$inc[combined2$income=="$40,000 to $49,999"]<-5
combined2$inc[combined2$income=="$50,000 to $59,999"]<-6
combined2$inc[combined2$income=="$60,000 to $69,999"]<-7
combined2$inc[combined2$income=="$70,000 to $79,999"]<-8
combined2$inc[combined2$income=="$80,000 to $89,999"]<-9
combined2$inc[combined2$income=="$90,000 to $99,999"]<-10
combined2$inc[combined2$income=="$100,000 to $124,999"]<-11
combined2$inc[combined2$income=="$150,000 to $199,999"]<-12
combined2$inc[combined2$income=="200,000 or more"]<-13

table(combined2$inc)
## 
##   1   2   3   4   5   6   7   8   9  10  11  12 
##  81 105 133 181 132 102  97  65  52  41  69  24
#centering
combined2$incCentered<-combined2$inc - mean(combined2$inc)
summary(combined2$incCentered)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
## -4.3697 -2.3697 -0.3697  0.0000  1.6303  6.6303
summary(aov(SS~cond + eduCentered + eduCentered*cond, data=combined2))
##                    Df Sum Sq Mean Sq F value   Pr(>F)    
## cond                2   1.72   0.861   3.526   0.0298 *  
## eduCentered         1   4.76   4.758  19.478 1.12e-05 ***
## cond:eduCentered    2   0.94   0.468   1.917   0.1475    
## Residuals        1076 262.82   0.244                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS~cond + incCentered + incCentered*cond, data=combined2))
##                    Df Sum Sq Mean Sq F value  Pr(>F)   
## cond                2   1.72  0.8613   3.484 0.03102 * 
## incCentered         1   2.17  2.1704   8.781 0.00311 **
## cond:incCentered    2   0.38  0.1896   0.767 0.46459   
## Residuals        1076 265.96  0.2472                   
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS~cond + gender + gender*cond, data=combined2))
##              Df Sum Sq Mean Sq F value Pr(>F)  
## cond          2   1.22  0.6118   2.447 0.0871 .
## gender        2   0.39  0.1943   0.777 0.4600  
## cond:gender   3   0.38  0.1271   0.508 0.6766  
## Residuals   904 225.97  0.2500                 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 170 observations deleted due to missingness
summary(aov(SS~cond + age + age*cond, data=combined2))
##               Df Sum Sq Mean Sq F value Pr(>F)  
## cond           2   1.72  0.8613   3.455 0.0319 *
## age            1   0.22  0.2165   0.868 0.3516  
## cond:age       2   0.07  0.0374   0.150 0.8606  
## Residuals   1076 268.22  0.2493                 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS ~ cond*age*bd, data=combined2))
##               Df Sum Sq Mean Sq F value   Pr(>F)    
## cond           2   1.72   0.861   3.799   0.0227 *  
## age            1   0.22   0.216   0.955   0.3287    
## bd             1  19.72  19.723  86.994  < 2e-16 ***
## cond:age       2   0.01   0.004   0.017   0.9835    
## cond:bd        2   5.11   2.553  11.261 1.45e-05 ***
## age:bd         1   0.24   0.244   1.077   0.2995    
## cond:age:bd    2   0.63   0.315   1.388   0.2499    
## Residuals   1070 242.58   0.227                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS ~ cond*eduCentered*bd, data=combined2))
##                       Df Sum Sq Mean Sq F value   Pr(>F)    
## cond                   2   1.72   0.861   3.825   0.0221 *  
## eduCentered            1   4.76   4.758  21.129 4.81e-06 ***
## bd                     1  17.17  17.172  76.264  < 2e-16 ***
## cond:eduCentered       2   0.91   0.453   2.013   0.1341    
## cond:bd                2   4.47   2.236   9.931 5.33e-05 ***
## eduCentered:bd         1   0.22   0.224   0.994   0.3191    
## cond:eduCentered:bd    2   0.05   0.027   0.119   0.8882    
## Residuals           1070 240.93   0.225                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS ~ cond*incCentered*bd, data=combined2))
##                       Df Sum Sq Mean Sq F value   Pr(>F)    
## cond                   2   1.72   0.861   3.814  0.02236 *  
## incCentered            1   2.17   2.170   9.612  0.00198 ** 
## bd                     1  18.74  18.736  82.972  < 2e-16 ***
## cond:incCentered       2   0.30   0.151   0.667  0.51349    
## cond:bd                2   5.16   2.581  11.429 1.23e-05 ***
## incCentered:bd         1   0.18   0.178   0.789  0.37451    
## cond:incCentered:bd    2   0.34   0.171   0.757  0.46929    
## Residuals           1070 241.62   0.226                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
summary(aov(SS ~ cond*gender*bd, data=combined2))
##                 Df Sum Sq Mean Sq F value   Pr(>F)    
## cond             2   1.22   0.612   2.704   0.0675 .  
## gender           2   0.39   0.194   0.859   0.4241    
## bd               1  16.01  16.009  70.753  < 2e-16 ***
## cond:gender      3   0.36   0.119   0.524   0.6656    
## cond:bd          2   6.14   3.070  13.566 1.57e-06 ***
## gender:bd        2   0.55   0.275   1.216   0.2968    
## cond:gender:bd   2   0.33   0.165   0.730   0.4824    
## Residuals      897 202.96   0.226                     
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 170 observations deleted due to missingness

FIGURES

combined2$cond2[combined2$cond=="no"]<-"Control"
combined2$cond2[combined2$cond=="LL"]<-"LL"
combined2$cond2[combined2$cond=="SS"]<-"SS"

SScontrol<-subset(combined2, cond2!="LL")
f1<-(glm(SS~cond2*bd_not_centered, data=SScontrol, family="binomial"))
library(visreg)
col<-c("black", "blue")
col2<-c("gray80", "cornflowerblue")
col3<-adjustcolor(col2, alpha=.7)
visreg(f1, "bd_not_centered", by="cond2", line=list(col=col), fill=list(col=col3), overlay=TRUE, partial=FALSE,  scale="response", xlab="Subjective Present Value of LL", ylab="Percent Choosing SS")

LLcontrol<-subset(combined2, cond2!="SS")

f2<-(glm(SS~cond2*bd_not_centered, data=LLcontrol,family="binomial"))
col<-c("black", "red")
col2<-c( "gray80", "indianred1" )
col3<-adjustcolor(col2, alpha=.45)
visreg(f2, "bd_not_centered", by="cond2", line=list(col=col), fill=list(col=col3), overlay=TRUE, partial=FALSE,  xlab="Subjective present value of LL", scale="response", ylab="P (choosing SS)")

#REACTANCE GRAPHS AS REQUESTED, ALTHOUGH THERE IS ONLY REACTANCE DATA FOR ABOUT HALF THE SAMPLE

f3<-(lm(reactance~cond2*bd_not_centered, data=combined2))
col<-c("black", "red", "blue")
col2<-c( "gray80", "indianred1" , "cornflowerblue")
col3<-adjustcolor(col2, alpha=.45)
visreg(f3, "bd_not_centered", by="cond2", line=list(col=col), fill=list(col=col3), overlay=TRUE, partial=FALSE,  xlab="Subjective present value of LL", scale="response", ylab="Reactance")

cdata <- ddply(combined2, c("quintiles", "cond"), summarise,
               N    = length(reactance),
               mean = mean(reactance, na.rm = T),
               sd   = sd(reactance, na.rm = T),
               se   = sd / sqrt(N))

## this is with 95% confidence interval
ggplot(cdata, aes(x=quintiles, y=mean, colour=cond)) + 
    geom_errorbar(aes(ymin=mean-se, ymax=mean+se), width=.1) +
    geom_line() +
    geom_point()