library(tidyverse)
library(ggplot2)
library(ggpubr)
library(plyr)
library(magick)
library(png)
library(lme4)
library(lmerTest)
library(irrNA)
library(psy)
library(coefficientalpha)
library(parameters)
library(dplyr)
rensink_new <- list.files(path = "/Users/adambarnas/Box/MetaAwareness/data/Rensink_New", pattern = "*.csv", full.names = T, ignore.case = F) %>%
map_df(~read.csv(., colClasses=c("gender..m.f."="character", "a"="character", "tp_a"="character")))
Get a count of the number of new subjects.
nrow(rensink_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 36
rensink_new_bad_catch <- rensink_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys < 4) | (any(Garden_resp.keys > 2)))
nrow(rensink_new_bad_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 15
rensink_new_good_catch <- rensink_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys >= 4) & (any(Garden_resp.keys <= 2) | is.na(any(Garden_resp.keys))))
nrow(rensink_new_good_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 21
rensink_new_good_catch = subset(rensink_new_good_catch, select = c(user_resp.keys,user_resp.rt,workerId,image_a))
col_idx <- grep("workerId", names(rensink_new_good_catch))
rensink_new_good_catch <- rensink_new_good_catch[, c(col_idx, (1:ncol(rensink_new_good_catch))[-col_idx])]
rensink_new_good_catch <- data.frame(na.omit(rensink_new_good_catch))
rensink_new_good_catch <- rensink_new_good_catch %>%
separate(image_a,into=c('database', 'image'), sep = "([\\_])", extra = "merge")
rensink_new_good_catch$image <- lapply(rensink_new_good_catch$image, gsub, pattern='-a_w_outline.jpg', replacement='')
rensink_new_good_catch <- rensink_new_good_catch %>%
mutate(image = as.character(image))
colnames(rensink_new_good_catch) <- c("workerId", "likelihood_rating", "likelihood_rating_rt", "stim_set", "image")
rensink_new_good_catch <- rensink_new_good_catch %>%
drop_na(image)
rensink_new_good_catch_likelihood_count <- rensink_new_good_catch %>%
group_by(workerId,image) %>%
dplyr::summarize(counts = n()) %>%
spread(image,counts) %>%
mutate(sum = rowSums(.[-1], na.rm = TRUE))
#head(tbl_all_counts,10)
rensink_new_good_catch_likelihood_count <- data.frame(count = colSums(rensink_new_good_catch_likelihood_count[,2:49], na.rm = TRUE))
rensink_new_good_catch_likelihood_count <- tibble::rownames_to_column(rensink_new_good_catch_likelihood_count, "image")
rensink_new_good_catch_likelihood_count
## image count
## 1 Amish 13
## 2 Army 16
## 3 Barns 13
## 4 BarnTrack 15
## 5 Barrels 13
## 6 Beach 14
## 7 Birds 14
## 8 Boat 12
## 9 Bus 14
## 10 Cactus 15
## 11 Camel 11
## 12 CanalBridge 10
## 13 Castle 7
## 14 Chopper 13
## 15 Cockpit 13
## 16 Description 12
## 17 Dinner 16
## 18 Diver 13
## 19 Eating 15
## 20 Egypt 14
## 21 FarmByPond 15
## 22 Farmer 12
## 23 Fishing 15
## 24 Floatplane 10
## 25 Fountain 14
## 26 Harbor 12
## 27 Horizon 12
## 28 Ice 11
## 29 Kayak 14
## 30 Kayaker 14
## 31 Kids 16
## 32 Lake 15
## 33 Market 12
## 34 Marling 12
## 35 Mosque 15
## 36 NotreDame 17
## 37 Nurses 14
## 38 Obelisk 12
## 39 OtherDiver 10
## 40 Pilots 15
## 41 Seal 12
## 42 Soldiers 13
## 43 Station 10
## 44 SummerLake 14
## 45 Turtle 12
## 46 Water 8
## 47 Window 15
## 48 Wine 16
rensink_new_good_catch <- rensink_new_good_catch %>%
drop_na()
rensink_new_good_catch %>%
ggbarplot(x = "image", y = "likelihood_rating", ylab = "Mean Likelihood of Detecting Change", ylim = c(1,5), xlab = "Image", fill = "#f7a800", add = "mean_se", font.xtickslab = 8, sort.val = c("asc")) + rotate_x_text() + theme(legend.position = "none")
ma_new <- list.files(path = "/Users/adambarnas/Box/MetaAwareness/data/Ma_New", pattern = "*.csv", full.names = T, ignore.case = F) %>%
map_df(~read.csv(., colClasses=c("gender..m.f."="character", "a"="character", "tp_a"="character")))
Get a count of the number of new subjects.
nrow(ma_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 45
ma_new_bad_catch <- ma_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys < 4) | (any(Garden_resp.keys > 2)))
nrow(ma_new_bad_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 13
ma_new_good_catch <- ma_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys >= 4) & (any(Garden_resp.keys <= 2) | is.na(any(Garden_resp.keys))))
nrow(ma_new_good_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 32
ma_new_good_catch = subset(ma_new_good_catch, select = c(user_resp.keys,user_resp.rt,workerId,image_a))
col_idx <- grep("workerId", names(ma_new_good_catch))
ma_new_good_catch <- ma_new_good_catch[, c(col_idx, (1:ncol(ma_new_good_catch))[-col_idx])]
ma_new_good_catch <- data.frame(na.omit(ma_new_good_catch))
ma_new_good_catch <- ma_new_good_catch %>%
separate(image_a,into=c('database', 'image'), sep = "([\\_])", extra = "merge")
ma_new_good_catch$image <- lapply(ma_new_good_catch$image, gsub, pattern='-a_w_outline.jpg', replacement='')
ma_new_good_catch <- ma_new_good_catch %>%
mutate(image = as.character(image))
colnames(ma_new_good_catch) <- c("workerId", "likelihood_rating", "likelihood_rating_rt", "stim_set", "image")
ma_new_good_catch <- ma_new_good_catch %>%
drop_na(image)
ma_new_good_catch_likelihood_count <- ma_new_good_catch %>%
group_by(workerId,image) %>%
dplyr::summarize(counts = n()) %>%
spread(image,counts) %>%
mutate(sum = rowSums(.[-1], na.rm = TRUE))
#head(tbl_all_counts,10)
ma_new_good_catch_likelihood_count <- data.frame(count = colSums(ma_new_good_catch_likelihood_count[,2:70], na.rm = TRUE))
ma_new_good_catch_likelihood_count <- tibble::rownames_to_column(ma_new_good_catch_likelihood_count, "image")
ma_new_good_catch_likelihood_count
## image count
## 1 10504629 19
## 2 10810329 11
## 3 1191801 15
## 4 12115280 14
## 5 12178414 12
## 6 13141692 14
## 7 1383096 12
## 8 13873251 12
## 9 16527526 13
## 10 18169626 15
## 11 18345691 13
## 12 22020472 12
## 13 23024660 16
## 14 23199105 17
## 15 24383097 13
## 16 25107991 12
## 17 27857618 13
## 18 3099758 10
## 19 31236119 15
## 20 32289063 11
## 21 38466626 14
## 22 38546029 16
## 23 42429798 20
## 24 4247084 17
## 25 44993860 11
## 26 45525109 15
## 27 46475259 12
## 28 46635293 18
## 29 48384711 11
## 30 48486405 22
## 31 51537628 9
## 32 51856108 9
## 33 55174490 14
## 34 56835136 15
## 35 57861456 14
## 36 61118260 13
## 37 62096551 13
## 38 62224663 15
## 39 67862299 17
## 40 69128765 14
## 41 70687495 12
## 42 72488522 14
## 43 73637203 13
## 44 74173745 10
## 45 75081153 15
## 46 75958241 18
## 47 77345858 10
## 48 77574131 17
## 49 77793328 16
## 50 79191795 14
## 51 79222679 11
## 52 79241011 9
## 53 79573638 12
## 54 8197559 15
## 55 81993755 15
## 56 83536470 12
## 57 83691215 10
## 58 83785171 11
## 59 85741618 13
## 60 86520382 17
## 61 87983207 14
## 62 88767165 17
## 63 89354846 16
## 64 8974554 16
## 65 90405028 9
## 66 95091295 16
## 67 97475929 15
## 68 98156944 18
## 69 98265889 17
ma_new_good_catch <- ma_new_good_catch %>%
drop_na()
ma_new_good_catch %>%
ggbarplot(x = "image", y = "likelihood_rating", ylab = "Mean Likelihood of Detecting Change", ylim = c(1,5), xlab = "Image", fill = "#f7a800", add = "mean_se", font.xtickslab = 6, sort.val = c("asc")) + rotate_x_text() + theme(legend.position = "none")
wolfe1_new <- list.files(path = "/Users/adambarnas/Box/MetaAwareness/data/Wolfe1_New", pattern = "*.csv", full.names = T, ignore.case = F) %>%
map_df(~read.csv(., colClasses=c("gender..m.f."="character", "a"="character", "tp_a"="character")))
Get a count of the number of new subjects.
nrow(wolfe1_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 88
wolfe1_new_bad_catch <- wolfe1_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys < 4) | (any(Garden_resp.keys > 2)))
nrow(wolfe1_new_bad_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 29
wolfe1_new_good_catch <- wolfe1_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys >= 4) & (any(Garden_resp.keys <= 2) | is.na(any(Garden_resp.keys))))
nrow(wolfe1_new_good_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 59
wolfe1_new_good_catch = subset(wolfe1_new_good_catch, select = c(user_resp.keys,user_resp.rt,workerId,image_a))
col_idx <- grep("workerId", names(wolfe1_new_good_catch))
wolfe1_new_good_catch <- wolfe1_new_good_catch[, c(col_idx, (1:ncol(wolfe1_new_good_catch))[-col_idx])]
wolfe1_new_good_catch <- data.frame(na.omit(wolfe1_new_good_catch))
wolfe1_new_good_catch <- wolfe1_new_good_catch %>%
separate(image_a,into=c('database', 'image'), sep = "([\\_])", extra = "merge")
wolfe1_new_good_catch$image <- lapply(wolfe1_new_good_catch$image, gsub, pattern='-a_w_outline.jpg', replacement='')
wolfe1_new_good_catch <- wolfe1_new_good_catch %>%
mutate(image = as.character(image))
colnames(wolfe1_new_good_catch) <- c("workerId", "likelihood_rating", "likelihood_rating_rt", "stim_set", "image")
wolfe1_new_good_catch$stim_set = "wolfe1"
wolfe1_new_good_catch <- wolfe1_new_good_catch %>%
drop_na(image)
wolfe1_new_good_catch_likelihood_count <- wolfe1_new_good_catch %>%
group_by(workerId,image) %>%
dplyr::summarize(counts = n()) %>%
spread(image,counts) %>%
mutate(sum = rowSums(.[-1], na.rm = TRUE))
#head(tbl_all_counts,10)
wolfe1_new_good_catch_likelihood_count <- data.frame(count = colSums(wolfe1_new_good_catch_likelihood_count[,2:112], na.rm = TRUE))
wolfe1_new_good_catch_likelihood_count <- tibble::rownames_to_column(wolfe1_new_good_catch_likelihood_count, "image")
wolfe1_new_good_catch_likelihood_count
## image count
## 1 image-001 18
## 2 image-002 17
## 3 image-003 14
## 4 image-004 24
## 5 image-005 13
## 6 image-006 13
## 7 image-007 11
## 8 image-008 13
## 9 image-009 19
## 10 image-010 20
## 11 image-011 19
## 12 image-012 14
## 13 image-013 13
## 14 image-014 17
## 15 image-015 12
## 16 image-016 19
## 17 image-017 20
## 18 image-018 11
## 19 image-019 24
## 20 image-020 10
## 21 image-021 18
## 22 image-022 18
## 23 image-023 14
## 24 image-024 21
## 25 image-025 19
## 26 image-026 16
## 27 image-027 21
## 28 image-028 14
## 29 image-029 14
## 30 image-030 17
## 31 image-031 19
## 32 image-032 22
## 33 image-033 18
## 34 image-034 18
## 35 image-035 10
## 36 image-037 16
## 37 image-038 14
## 38 image-039 11
## 39 image-040 14
## 40 image-041 14
## 41 image-042 17
## 42 image-043 15
## 43 image-044 20
## 44 image-045 17
## 45 image-046 12
## 46 image-047 15
## 47 image-048 16
## 48 image-049 15
## 49 image-050 14
## 50 image-076 18
## 51 image-077 18
## 52 image-078 15
## 53 image-079 17
## 54 image-080 19
## 55 image-081 10
## 56 image-082 18
## 57 image-083 18
## 58 image-084 16
## 59 image-085 15
## 60 image-086 10
## 61 image-087 14
## 62 image-088 16
## 63 image-089 14
## 64 image-090 16
## 65 image-091 18
## 66 image-092 12
## 67 image-093 17
## 68 image-094 19
## 69 image-095 17
## 70 image-096 11
## 71 image-097 17
## 72 image-098 15
## 73 image-099 16
## 74 image-100 21
## 75 image-101 23
## 76 image-102 22
## 77 image-103 19
## 78 image-104 12
## 79 image-105 13
## 80 image-106 16
## 81 image-107 13
## 82 image-108 10
## 83 image-109 12
## 84 image-110 12
## 85 image-111 13
## 86 image-112 17
## 87 image-113 10
## 88 image-114 18
## 89 image-115 18
## 90 image-116 12
## 91 image-117 20
## 92 image-118 12
## 93 image-119 20
## 94 image-120 18
## 95 image-121 16
## 96 image-122 16
## 97 image-123 14
## 98 image-124 15
## 99 image-125 13
## 100 image-126 19
## 101 image-127 13
## 102 image-128 15
## 103 image-129 15
## 104 image-130 13
## 105 image-131 16
## 106 image-132 14
## 107 image-133 22
## 108 image-134 13
## 109 image-135 13
## 110 image-136 17
## 111 image-137 29
wolfe1_new_good_catch <- wolfe1_new_good_catch %>%
drop_na()
wolfe1_new_good_catch %>%
ggbarplot(x = "image", y = "likelihood_rating", ylab = "Mean Likelihood of Detecting Change", ylim = c(1,5), xlab = "Image", fill = "#f7a800", add = "mean_se", font.xtickslab = 4, sort.val = c("asc")) + rotate_x_text() + theme(legend.position = "none")
wolfe2_new <- list.files(path = "/Users/adambarnas/Box/MetaAwareness/data/Wolfe2_New", pattern = "*.csv", full.names = T, ignore.case = F) %>%
map_df(~read.csv(., colClasses=c("gender..m.f."="character", "a"="character", "tp_a"="character")))
Get a count of the number of new subjects.
nrow(wolfe2_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 174
wolfe2_new_bad_catch <- wolfe2_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys < 4) | (any(Garden_resp.keys > 2)))
nrow(wolfe2_new_bad_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 66
wolfe2_new_good_catch <- wolfe2_new %>%
group_by(workerId) %>%
filter(any(Cow_resp.keys >= 4) & (any(Garden_resp.keys <= 2) | is.na(any(Garden_resp.keys))))
nrow(wolfe2_new_good_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 108
wolfe2_new_good_catch = subset(wolfe2_new_good_catch, select = c(user_resp.keys,user_resp.rt,workerId,image_a))
col_idx <- grep("workerId", names(wolfe2_new_good_catch))
wolfe2_new_good_catch <- wolfe2_new_good_catch[, c(col_idx, (1:ncol(wolfe2_new_good_catch))[-col_idx])]
wolfe2_new_good_catch <- data.frame(na.omit(wolfe2_new_good_catch))
wolfe2_new_good_catch <- wolfe2_new_good_catch %>%
separate(image_a,into=c('database', 'image'), sep = "([\\_])", extra = "merge")
wolfe2_new_good_catch$image <- lapply(wolfe2_new_good_catch$image, gsub, pattern='-a_w_outline.jpg', replacement='')
wolfe2_new_good_catch <- wolfe2_new_good_catch %>%
mutate(image = as.character(image))
colnames(wolfe2_new_good_catch) <- c("workerId", "likelihood_rating", "likelihood_rating_rt", "stim_set", "image")
wolfe2_new_good_catch$stim_set = "wolfe2"
wolfe2_new_good_catch <- wolfe2_new_good_catch %>%
drop_na(image)
wolfe2_new_good_catch_likelihood_count <- wolfe2_new_good_catch %>%
group_by(workerId,image) %>%
dplyr::summarize(counts = n()) %>%
spread(image,counts) %>%
mutate(sum = rowSums(.[-1], na.rm = TRUE))
#head(tbl_all_counts,10)
wolfe2_new_good_catch_likelihood_count <- data.frame(count = colSums(wolfe2_new_good_catch_likelihood_count[,2:255], na.rm = TRUE))
wolfe2_new_good_catch_likelihood_count <- tibble::rownames_to_column(wolfe2_new_good_catch_likelihood_count, "image")
wolfe2_new_good_catch_likelihood_count
## image count
## 1 001_L_mirror 17
## 2 001_R_mirror 11
## 3 002_L_napkin 15
## 4 002_R_napkin 9
## 5 003_L_ducks 17
## 6 003_R_ducks 12
## 7 004_L_electricalgrid 17
## 8 004_R_electricalgrid 11
## 9 005_L_mirror 13
## 10 005_R_mirror 16
## 11 006_L_vase 13
## 12 006_R_vase 12
## 13 007_L_soap 11
## 14 007_R_soap 14
## 15 008_L_bottle 14
## 16 008_R_bottle 16
## 17 009_L_carpet 10
## 18 009_R_carpet 11
## 19 010_L_candle 10
## 20 010_R_candle 14
## 21 011_L_parfum 10
## 22 011_R_parfum 8
## 23 012_L_tubaccesory 11
## 24 012_R_tubaccesory 14
## 25 013_L_lamp 14
## 26 013_R_lamp 13
## 27 014_L_lamp 14
## 28 014_R_lamp 12
## 29 015_L_ceilinglight 10
## 30 015_R_ceilinglight 14
## 31 016_L_art 16
## 32 016_R_art 13
## 33 017_L_wood 9
## 34 017_R_wood 13
## 35 018_L_plant 15
## 36 018_R_plant 14
## 37 019_L_lamp_sized 11
## 38 019_R_lamp_sized 13
## 39 020_L_walldeco 14
## 40 020_R_walldeco 12
## 41 021_L_keyboard 14
## 42 021_R_keyboard 9
## 43 022_L_lamp 12
## 44 022_R_lamp 9
## 45 023_L_remote 12
## 46 023_R_remote 13
## 47 024_L_towels 16
## 48 024_R_towels 9
## 49 025_L_vase 11
## 50 025_R_vase 9
## 51 026_L_rack 15
## 52 026_R_rack 10
## 53 027_L_soapdish 17
## 54 027_R_soapdish 13
## 55 028_L_vase 17
## 56 028_R_vase 8
## 57 029_L_glass 20
## 58 029_R_glass 8
## 59 030_L_drawer 15
## 60 030_R_drawer 7
## 61 031_L_log 13
## 62 031_R_log 13
## 63 032_L_bottle 13
## 64 032_R_bottle 12
## 65 033_L_vase 17
## 66 033_R_vase 11
## 67 034_L_handle 16
## 68 034_R_handle 9
## 69 035_L_fruit 15
## 70 035_R_fruit 11
## 71 036_L_bowl 14
## 72 036_R_bowl 10
## 73 037_L_towel 12
## 74 037_R_towel 18
## 75 038_L_art 12
## 76 038_R_art 12
## 77 039_L_ventilator 20
## 78 039_R_ventilator 9
## 79 040_L_painting 15
## 80 040_R_painting 14
## 81 041_L_fruit 13
## 82 041_R_fruit 15
## 83 042_L_tap 21
## 84 042_R_tap 7
## 85 043_L_clock 10
## 86 043_R_clock 9
## 87 044_L_light 14
## 88 044_R_light 7
## 89 045_L_musicdock 14
## 90 045_R_musicdock 13
## 91 046_L_remote 8
## 92 046_R_remote 10
## 93 047_L_handle 9
## 94 047_R_handle 17
## 95 048_L_art 14
## 96 048_R_art 10
## 97 049_L_painting 15
## 98 049_R_painting 10
## 99 050_L_book 19
## 100 050_R_book 13
## 101 051_L_owl 14
## 102 051_R_owl 12
## 103 052_L_speaker 14
## 104 052_R_speaker 12
## 105 053_L_handle 14
## 106 053_R_handle 10
## 107 054_L_firewood 12
## 108 054_R_firewood 11
## 109 055_L_carpet 15
## 110 055_R_carpet 10
## 111 056_L_comforter 9
## 112 056_R_comforter 14
## 113 057_L_bin 13
## 114 057_R_bin 7
## 115 058_L_clutch 10
## 116 058_R_clutch 10
## 117 059_L_car 16
## 118 059_R_car 13
## 119 060_L_pillow 10
## 120 060_R_pillow 18
## 121 061_L_glass 19
## 122 061_R_glass 9
## 123 062_L_flowers 9
## 124 062_R_flowers 7
## 125 063_L_laptop 8
## 126 063_R_laptop 12
## 127 064_L_bottles 17
## 128 064_R_bottles 9
## 129 065_L_cd 15
## 130 065_R_cd 12
## 131 066_L_vase 7
## 132 066_R_vase 11
## 133 067_L_painting 14
## 134 067_R_painting 9
## 135 068_L_faucet 18
## 136 068_R_faucet 14
## 137 069_L_things 20
## 138 069_R_things 13
## 139 070_L_lamp 12
## 140 070_R_lamp 17
## 141 071_L_art 14
## 142 071_R_art 10
## 143 072_L_handle 14
## 144 072_R_handle 12
## 145 073_L_coffeemug 18
## 146 073_R_coffeemug 12
## 147 074_L_book 12
## 148 074_R_book 14
## 149 075_L_light 15
## 150 075_R_light 12
## 151 076_L_hook 13
## 152 076_R_hook 12
## 153 077_L_footrest 13
## 154 077_R_footrest 18
## 155 078_L_faucet 14
## 156 078_R_faucet 10
## 157 079_L_bowl 16
## 158 079_R_bowl 14
## 159 080_L_plant 13
## 160 080_R_plant 9
## 161 081_L_football 17
## 162 081_R_football 6
## 163 082_L_bowl 16
## 164 082_R_bowl 5
## 165 083_L_knob 15
## 166 083_R_knob 9
## 167 084_L_light 16
## 168 084_R_light 11
## 169 085_L_switchboard 19
## 170 085_R_switchboard 20
## 171 086_L_book 12
## 172 086_R_book 8
## 173 087_L_towelhandle 19
## 174 087_R_towelhandle 13
## 175 088_L_clock 14
## 176 088_R_clock 10
## 177 089_L_poster 17
## 178 089_R_poster 12
## 179 090_L_lamp 15
## 180 090_R_lamp 11
## 181 091_L_airfreshener 12
## 182 091_R_airfreshener 10
## 183 092_L_candles 15
## 184 092_R_candles 7
## 185 093_L_switch 17
## 186 093_R_switch 10
## 187 095_L_candle 16
## 188 095_R_candle 14
## 189 096_L_painting 15
## 190 096_R_painting 14
## 191 097_L_light 14
## 192 097_R_light 14
## 193 098_L_slippers 13
## 194 098_R_slippers 11
## 195 099_L_sconce 14
## 196 099_R_sconce 13
## 197 100_L_mirror 13
## 198 100_R_mirror 16
## 199 101_L_cup 15
## 200 101_R_cup 11
## 201 102_L_shoppingbag 12
## 202 102_R_shoppingbag 11
## 203 103_L_hook 9
## 204 103_R_hook 13
## 205 104_L_bottle 14
## 206 104_R_bottle 9
## 207 105_L_hat 11
## 208 105_R_hat 12
## 209 106_L_toweldispenser 11
## 210 106_R_toweldispenser 10
## 211 107_L_shirts 15
## 212 107_R_shirts 10
## 213 108_L_boa 15
## 214 108_R_boa 14
## 215 109_L_pillow 11
## 216 109_R_pillow 15
## 217 110_L_plant 12
## 218 110_R_plant 11
## 219 111_L_pot 13
## 220 111_R_pot 10
## 221 112_L_basket 16
## 222 112_R_basket 15
## 223 113_L_plant 15
## 224 113_R_plant 12
## 225 114_L_bird 11
## 226 114_R_bird 13
## 227 115_L_pot 10
## 228 115_R_pot 20
## 229 116_L_basket 8
## 230 116_R_basket 12
## 231 117_L_plant_sized 15
## 232 117_R_plant_sized 12
## 233 118_L_shoes 14
## 234 118_R_shoes 13
## 235 119_L_painting 14
## 236 119_R_painting 8
## 237 120_L_art 18
## 238 120_R_art 15
## 239 121_L_car 14
## 240 121_R_car 4
## 241 122_L_chair 12
## 242 122_R_chair 9
## 243 123_L_pot 11
## 244 123_R_pot 6
## 245 124_L_vase 13
## 246 124_R_vase 14
## 247 125_L_sofa 13
## 248 125_R_sofa 11
## 249 126_L_candles 20
## 250 126_R_candles 6
## 251 127_L_light 18
## 252 127_R_light 11
## 253 128_L_pot 19
## 254 128_R_pot 19
wolfe2_new_good_catch <- wolfe2_new_good_catch %>%
drop_na()
wolfe2_new_good_catch %>%
ggbarplot(x = "image", y = "likelihood_rating", ylab = "Mean Likelihood of Detecting Change", ylim = c(1,5), xlab = "Image", fill = "#f7a800", add = "mean_se", font.xtickslab = 2, sort.val = c("asc")) + rotate_x_text() + theme(legend.position = "none")
Initial sample size.
nrow(rensink_new %>% distinct(workerId,.keep_all = FALSE)) + nrow(ma_new %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe1_new %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe2_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 343
Number of subjects who missed a catch trial.
nrow(rensink_new_bad_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(ma_new_bad_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe1_new_bad_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe2_new_bad_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 123
Number of subjects in final sample.
nrow(rensink_new_good_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(ma_new_good_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe1_new_good_catch %>% distinct(workerId,.keep_all = FALSE)) + nrow(wolfe2_new_good_catch %>% distinct(workerId,.keep_all = FALSE))
## [1] 220
Compute average likelihood rating.
new_ratings <- rbind(rensink_new_good_catch, ma_new_good_catch, wolfe1_new_good_catch, wolfe2_new_good_catch)
new_ratings_changetype_avg <- new_ratings %>%
group_by(workerId,image) %>%
dplyr::summarize(average = mean(likelihood_rating)) %>%
spread(image,average) %>%
mutate(subj_avg = rowMeans(.[-1], na.rm = TRUE))
mean(new_ratings_changetype_avg$subj_avg)
## [1] 2.977727
sd(new_ratings_changetype_avg$subj_avg)
## [1] 0.713872
range(new_ratings_changetype_avg$subj_avg)
## [1] 1.3 5.0
new_ratings_changetype_count <- new_ratings %>%
group_by(workerId,image) %>%
dplyr::summarize(counts = n()) %>%
spread(image,counts) %>%
mutate(sum = rowSums(.[-1], na.rm = TRUE))
#head(tbl_all_counts,10)
new_ratings_changetype_count <- data.frame(count = colSums(new_ratings_changetype_count[,2:483], na.rm = TRUE))
new_ratings_changetype_count <- tibble::rownames_to_column(new_ratings_changetype_count, "image")
new_ratings_changetype_count
## image count
## 1 001_L_mirror 17
## 2 001_R_mirror 11
## 3 002_L_napkin 15
## 4 002_R_napkin 9
## 5 003_L_ducks 17
## 6 003_R_ducks 12
## 7 004_L_electricalgrid 17
## 8 004_R_electricalgrid 11
## 9 005_L_mirror 13
## 10 005_R_mirror 16
## 11 006_L_vase 13
## 12 006_R_vase 12
## 13 007_L_soap 11
## 14 007_R_soap 14
## 15 008_L_bottle 14
## 16 008_R_bottle 16
## 17 009_L_carpet 10
## 18 009_R_carpet 11
## 19 010_L_candle 10
## 20 010_R_candle 14
## 21 011_L_parfum 10
## 22 011_R_parfum 8
## 23 012_L_tubaccesory 11
## 24 012_R_tubaccesory 14
## 25 013_L_lamp 14
## 26 013_R_lamp 13
## 27 014_L_lamp 14
## 28 014_R_lamp 12
## 29 015_L_ceilinglight 10
## 30 015_R_ceilinglight 14
## 31 016_L_art 16
## 32 016_R_art 13
## 33 017_L_wood 9
## 34 017_R_wood 13
## 35 018_L_plant 15
## 36 018_R_plant 14
## 37 019_L_lamp_sized 11
## 38 019_R_lamp_sized 13
## 39 020_L_walldeco 14
## 40 020_R_walldeco 12
## 41 021_L_keyboard 14
## 42 021_R_keyboard 9
## 43 022_L_lamp 12
## 44 022_R_lamp 9
## 45 023_L_remote 12
## 46 023_R_remote 13
## 47 024_L_towels 16
## 48 024_R_towels 9
## 49 025_L_vase 11
## 50 025_R_vase 9
## 51 026_L_rack 15
## 52 026_R_rack 10
## 53 027_L_soapdish 17
## 54 027_R_soapdish 13
## 55 028_L_vase 17
## 56 028_R_vase 8
## 57 029_L_glass 20
## 58 029_R_glass 8
## 59 030_L_drawer 15
## 60 030_R_drawer 7
## 61 031_L_log 13
## 62 031_R_log 13
## 63 032_L_bottle 13
## 64 032_R_bottle 12
## 65 033_L_vase 17
## 66 033_R_vase 11
## 67 034_L_handle 16
## 68 034_R_handle 9
## 69 035_L_fruit 15
## 70 035_R_fruit 11
## 71 036_L_bowl 14
## 72 036_R_bowl 10
## 73 037_L_towel 12
## 74 037_R_towel 18
## 75 038_L_art 12
## 76 038_R_art 12
## 77 039_L_ventilator 20
## 78 039_R_ventilator 9
## 79 040_L_painting 15
## 80 040_R_painting 14
## 81 041_L_fruit 13
## 82 041_R_fruit 15
## 83 042_L_tap 21
## 84 042_R_tap 7
## 85 043_L_clock 10
## 86 043_R_clock 9
## 87 044_L_light 14
## 88 044_R_light 7
## 89 045_L_musicdock 14
## 90 045_R_musicdock 13
## 91 046_L_remote 8
## 92 046_R_remote 10
## 93 047_L_handle 9
## 94 047_R_handle 17
## 95 048_L_art 14
## 96 048_R_art 10
## 97 049_L_painting 15
## 98 049_R_painting 10
## 99 050_L_book 19
## 100 050_R_book 13
## 101 051_L_owl 14
## 102 051_R_owl 12
## 103 052_L_speaker 14
## 104 052_R_speaker 12
## 105 053_L_handle 14
## 106 053_R_handle 10
## 107 054_L_firewood 12
## 108 054_R_firewood 11
## 109 055_L_carpet 15
## 110 055_R_carpet 10
## 111 056_L_comforter 9
## 112 056_R_comforter 14
## 113 057_L_bin 13
## 114 057_R_bin 7
## 115 058_L_clutch 10
## 116 058_R_clutch 10
## 117 059_L_car 16
## 118 059_R_car 13
## 119 060_L_pillow 10
## 120 060_R_pillow 18
## 121 061_L_glass 19
## 122 061_R_glass 9
## 123 062_L_flowers 9
## 124 062_R_flowers 7
## 125 063_L_laptop 8
## 126 063_R_laptop 12
## 127 064_L_bottles 17
## 128 064_R_bottles 9
## 129 065_L_cd 15
## 130 065_R_cd 12
## 131 066_L_vase 7
## 132 066_R_vase 11
## 133 067_L_painting 14
## 134 067_R_painting 9
## 135 068_L_faucet 18
## 136 068_R_faucet 14
## 137 069_L_things 20
## 138 069_R_things 13
## 139 070_L_lamp 12
## 140 070_R_lamp 17
## 141 071_L_art 14
## 142 071_R_art 10
## 143 072_L_handle 14
## 144 072_R_handle 12
## 145 073_L_coffeemug 18
## 146 073_R_coffeemug 12
## 147 074_L_book 12
## 148 074_R_book 14
## 149 075_L_light 15
## 150 075_R_light 12
## 151 076_L_hook 13
## 152 076_R_hook 12
## 153 077_L_footrest 13
## 154 077_R_footrest 18
## 155 078_L_faucet 14
## 156 078_R_faucet 10
## 157 079_L_bowl 16
## 158 079_R_bowl 14
## 159 080_L_plant 13
## 160 080_R_plant 9
## 161 081_L_football 17
## 162 081_R_football 6
## 163 082_L_bowl 16
## 164 082_R_bowl 5
## 165 083_L_knob 15
## 166 083_R_knob 9
## 167 084_L_light 16
## 168 084_R_light 11
## 169 085_L_switchboard 19
## 170 085_R_switchboard 20
## 171 086_L_book 12
## 172 086_R_book 8
## 173 087_L_towelhandle 19
## 174 087_R_towelhandle 13
## 175 088_L_clock 14
## 176 088_R_clock 10
## 177 089_L_poster 17
## 178 089_R_poster 12
## 179 090_L_lamp 15
## 180 090_R_lamp 11
## 181 091_L_airfreshener 12
## 182 091_R_airfreshener 10
## 183 092_L_candles 15
## 184 092_R_candles 7
## 185 093_L_switch 17
## 186 093_R_switch 10
## 187 095_L_candle 16
## 188 095_R_candle 14
## 189 096_L_painting 15
## 190 096_R_painting 14
## 191 097_L_light 14
## 192 097_R_light 14
## 193 098_L_slippers 13
## 194 098_R_slippers 11
## 195 099_L_sconce 14
## 196 099_R_sconce 13
## 197 100_L_mirror 13
## 198 100_R_mirror 16
## 199 101_L_cup 15
## 200 101_R_cup 11
## 201 102_L_shoppingbag 12
## 202 102_R_shoppingbag 11
## 203 103_L_hook 9
## 204 103_R_hook 13
## 205 104_L_bottle 14
## 206 104_R_bottle 9
## 207 105_L_hat 11
## 208 105_R_hat 12
## 209 10504629 19
## 210 106_L_toweldispenser 11
## 211 106_R_toweldispenser 10
## 212 107_L_shirts 15
## 213 107_R_shirts 10
## 214 108_L_boa 15
## 215 108_R_boa 14
## 216 10810329 11
## 217 109_L_pillow 11
## 218 109_R_pillow 15
## 219 110_L_plant 12
## 220 110_R_plant 11
## 221 111_L_pot 13
## 222 111_R_pot 10
## 223 112_L_basket 16
## 224 112_R_basket 15
## 225 113_L_plant 15
## 226 113_R_plant 12
## 227 114_L_bird 11
## 228 114_R_bird 13
## 229 115_L_pot 10
## 230 115_R_pot 20
## 231 116_L_basket 8
## 232 116_R_basket 12
## 233 117_L_plant_sized 15
## 234 117_R_plant_sized 12
## 235 118_L_shoes 14
## 236 118_R_shoes 13
## 237 119_L_painting 14
## 238 119_R_painting 8
## 239 1191801 15
## 240 120_L_art 18
## 241 120_R_art 15
## 242 121_L_car 14
## 243 121_R_car 4
## 244 12115280 14
## 245 12178414 12
## 246 122_L_chair 12
## 247 122_R_chair 9
## 248 123_L_pot 11
## 249 123_R_pot 6
## 250 124_L_vase 13
## 251 124_R_vase 14
## 252 125_L_sofa 13
## 253 125_R_sofa 11
## 254 126_L_candles 20
## 255 126_R_candles 6
## 256 127_L_light 18
## 257 127_R_light 11
## 258 128_L_pot 19
## 259 128_R_pot 19
## 260 13141692 14
## 261 1383096 12
## 262 13873251 12
## 263 16527526 13
## 264 18169626 15
## 265 18345691 13
## 266 22020472 12
## 267 23024660 16
## 268 23199105 17
## 269 24383097 13
## 270 25107991 12
## 271 27857618 13
## 272 3099758 10
## 273 31236119 15
## 274 32289063 11
## 275 38466626 14
## 276 38546029 16
## 277 42429798 20
## 278 4247084 17
## 279 44993860 11
## 280 45525109 15
## 281 46475259 12
## 282 46635293 18
## 283 48384711 11
## 284 48486405 22
## 285 51537628 9
## 286 51856108 9
## 287 55174490 14
## 288 56835136 15
## 289 57861456 14
## 290 61118260 13
## 291 62096551 13
## 292 62224663 15
## 293 67862299 17
## 294 69128765 14
## 295 70687495 12
## 296 72488522 14
## 297 73637203 13
## 298 74173745 10
## 299 75081153 15
## 300 75958241 18
## 301 77345858 10
## 302 77574131 17
## 303 77793328 16
## 304 79191795 14
## 305 79222679 11
## 306 79241011 9
## 307 79573638 12
## 308 8197559 15
## 309 81993755 15
## 310 83536470 12
## 311 83691215 10
## 312 83785171 11
## 313 85741618 13
## 314 86520382 17
## 315 87983207 14
## 316 88767165 17
## 317 89354846 16
## 318 8974554 16
## 319 90405028 9
## 320 95091295 16
## 321 97475929 15
## 322 98156944 18
## 323 98265889 17
## 324 Amish 13
## 325 Army 16
## 326 Barns 13
## 327 BarnTrack 15
## 328 Barrels 13
## 329 Beach 14
## 330 Birds 14
## 331 Boat 12
## 332 Bus 14
## 333 Cactus 15
## 334 Camel 11
## 335 CanalBridge 10
## 336 Castle 7
## 337 Chopper 13
## 338 Cockpit 13
## 339 Description 12
## 340 Dinner 16
## 341 Diver 13
## 342 Eating 15
## 343 Egypt 14
## 344 FarmByPond 15
## 345 Farmer 12
## 346 Fishing 15
## 347 Floatplane 10
## 348 Fountain 14
## 349 Harbor 12
## 350 Horizon 12
## 351 Ice 11
## 352 image-001 18
## 353 image-002 17
## 354 image-003 14
## 355 image-004 24
## 356 image-005 13
## 357 image-006 13
## 358 image-007 11
## 359 image-008 13
## 360 image-009 19
## 361 image-010 20
## 362 image-011 19
## 363 image-012 14
## 364 image-013 13
## 365 image-014 17
## 366 image-015 12
## 367 image-016 19
## 368 image-017 20
## 369 image-018 11
## 370 image-019 24
## 371 image-020 10
## 372 image-021 18
## 373 image-022 18
## 374 image-023 14
## 375 image-024 21
## 376 image-025 19
## 377 image-026 16
## 378 image-027 21
## 379 image-028 14
## 380 image-029 14
## 381 image-030 17
## 382 image-031 19
## 383 image-032 22
## 384 image-033 18
## 385 image-034 18
## 386 image-035 10
## 387 image-037 16
## 388 image-038 14
## 389 image-039 11
## 390 image-040 14
## 391 image-041 14
## 392 image-042 17
## 393 image-043 15
## 394 image-044 20
## 395 image-045 17
## 396 image-046 12
## 397 image-047 15
## 398 image-048 16
## 399 image-049 15
## 400 image-050 14
## 401 image-076 18
## 402 image-077 18
## 403 image-078 15
## 404 image-079 17
## 405 image-080 19
## 406 image-081 10
## 407 image-082 18
## 408 image-083 18
## 409 image-084 16
## 410 image-085 15
## 411 image-086 10
## 412 image-087 14
## 413 image-088 16
## 414 image-089 14
## 415 image-090 16
## 416 image-091 18
## 417 image-092 12
## 418 image-093 17
## 419 image-094 19
## 420 image-095 17
## 421 image-096 11
## 422 image-097 17
## 423 image-098 15
## 424 image-099 16
## 425 image-100 21
## 426 image-101 23
## 427 image-102 22
## 428 image-103 19
## 429 image-104 12
## 430 image-105 13
## 431 image-106 16
## 432 image-107 13
## 433 image-108 10
## 434 image-109 12
## 435 image-110 12
## 436 image-111 13
## 437 image-112 17
## 438 image-113 10
## 439 image-114 18
## 440 image-115 18
## 441 image-116 12
## 442 image-117 20
## 443 image-118 12
## 444 image-119 20
## 445 image-120 18
## 446 image-121 16
## 447 image-122 16
## 448 image-123 14
## 449 image-124 15
## 450 image-125 13
## 451 image-126 19
## 452 image-127 13
## 453 image-128 15
## 454 image-129 15
## 455 image-130 13
## 456 image-131 16
## 457 image-132 14
## 458 image-133 22
## 459 image-134 13
## 460 image-135 13
## 461 image-136 17
## 462 image-137 29
## 463 Kayak 14
## 464 Kayaker 14
## 465 Kids 16
## 466 Lake 15
## 467 Market 12
## 468 Marling 12
## 469 Mosque 15
## 470 NotreDame 17
## 471 Nurses 14
## 472 Obelisk 12
## 473 OtherDiver 10
## 474 Pilots 15
## 475 Seal 12
## 476 Soldiers 13
## 477 Station 10
## 478 SummerLake 14
## 479 Turtle 12
## 480 Water 8
## 481 Window 15
## 482 Wine 16
mean(new_ratings_changetype_count$count)
## [1] 13.69295
sd(new_ratings_changetype_count$count)
## [1] 3.376744
range(new_ratings_changetype_count$count)
## [1] 4 29
Do image-related properties (size of box, size of change, eccentricity, and change type) predict likelihood ratings? No, image-related properties do not predict likelihood ratings.
Box_and_change_info <- read_csv("/Users/adambarnas/Box/MetaAwareness/data/Box_and_change_info.csv")
Box_and_change_info <- Box_and_change_info %>%
filter(!grepl('catch', image)) %>%
separate(image,into=c('database', 'image'), sep = "([\\_])", extra = "merge")
Box_and_change_info$image <- lapply(Box_and_change_info$image, gsub, pattern='-a', replacement='')
Box_and_change_info$image <- as.character(Box_and_change_info$image)
new_changetype_boxsize_changesize_eccentricity <- left_join(new_ratings, Box_and_change_info, by = "image")
result_7.1 <- lmer(likelihood_rating ~ change_percent + eccentricity + (1 | workerId) + (1 | image) + (1 | stim_set), data=new_changetype_boxsize_changesize_eccentricity)
summary(result_7.1)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: likelihood_rating ~ change_percent + eccentricity + (1 | workerId) +
## (1 | image) + (1 | stim_set)
## Data: new_changetype_boxsize_changesize_eccentricity
##
## REML criterion at convergence: 19167.1
##
## Scaled residuals:
## Min 1Q Median 3Q Max
## -4.5261 -0.6203 0.0103 0.6295 3.9241
##
## Random effects:
## Groups Name Variance Std.Dev.
## image (Intercept) 6.016e-01 0.775637
## workerId (Intercept) 4.746e-01 0.688922
## stim_set (Intercept) 9.078e-06 0.003013
## Residual 8.145e-01 0.902511
## Number of obs: 6600, groups: image, 482; workerId, 220; stim_set, 4
##
## Fixed effects:
## Estimate Std. Error df t value Pr(>|t|)
## (Intercept) 2.852e+00 1.058e-01 6.434e+02 26.965 <2e-16 ***
## change_percent 2.808e-02 1.627e-02 6.296e+02 1.726 0.0849 .
## eccentricity 4.101e-04 4.405e-04 4.781e+02 0.931 0.3524
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Correlation of Fixed Effects:
## (Intr) chng_p
## chang_prcnt -0.198
## eccentricty -0.798 -0.021
## convergence code: 0
## unable to evaluate scaled gradient
## Model failed to converge: degenerate Hessian with 1 negative eigenvalues
ci(result_7.1)
## Parameter CI CI_low CI_high
## 1 (Intercept) 95 2.6445380151 3.059103183
## 2 change_percent 95 -0.0038095698 0.059968756
## 3 eccentricity 95 -0.0004533531 0.001273555
all_CB_MC_changetype_boxsize_changesize_eccentricity <- read_csv("/Users/adambarnas/Box/MetaAwareness/all_CB_MC_changetype_boxsize_changesize_eccentricity.csv", col_types = cols())
all_CB_MC_changetype_boxsize_changesize_eccentricity_condensed <- all_CB_MC_changetype_boxsize_changesize_eccentricity[, -c(7,8,9,10,11,12,13,15,16,18,19,20,21,22,23)]
all_CB_MC_changetype_boxsize_changesize_eccentricity_condensed$group = "Original"
return_log_avg <- all_CB_MC_changetype_boxsize_changesize_eccentricity_condensed %>%
group_by(workerId,image) %>%
dplyr::summarize(log_rt = mean(log_rt)) %>%
spread(image,log_rt) %>%
mutate(subj_avg = rowMeans(.[-1], na.rm = TRUE))
return_log_avg <- data.frame(log_rt = colMeans(return_log_avg[,2:482], na.rm = TRUE))
return_log_avg <- tibble::rownames_to_column(return_log_avg, "image")
return_likelihood_avg <- all_CB_MC_changetype_boxsize_changesize_eccentricity_condensed %>%
group_by(workerId,image) %>%
dplyr::summarize(likelihood_rating = mean(likelihood_rating)) %>%
spread(image,likelihood_rating) %>%
mutate(subj_avg = rowMeans(.[-1], na.rm = TRUE))
return_likelihood_avg <- data.frame(likelihood_rating = colMeans(return_likelihood_avg[,2:482], na.rm = TRUE))
return_likelihood_avg <- tibble::rownames_to_column(return_likelihood_avg, "image")
return <- left_join(return_log_avg, return_likelihood_avg, by = "image")
return$group = "Original"
return_corr <- cor.test(return$log_rt, return$likelihood_rating, method = c("pearson"))
return_corr
##
## Pearson's product-moment correlation
##
## data: return$log_rt and return$likelihood_rating
## t = -7.1917, df = 479, p-value = 2.478e-12
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.3906785 -0.2291642
## sample estimates:
## cor
## -0.3121753
new_ratings <- left_join(new_ratings, return_log_avg, by = "image")
new_changetype_boxsize_changesize_eccentricity <- left_join(new_ratings, Box_and_change_info, by = "image")
new_changetype_boxsize_changesize_eccentricity_condensed <- new_changetype_boxsize_changesize_eccentricity[, -c(7,8,9,10,11,12,13,15,16,18,19,20,21,22,23)]
new_likelihood_avg <- new_changetype_boxsize_changesize_eccentricity_condensed %>%
group_by(workerId,image) %>%
dplyr::summarize(likelihood_rating = mean(likelihood_rating)) %>%
spread(image,likelihood_rating) %>%
mutate(subj_avg = rowMeans(.[-1], na.rm = TRUE))
new_likelihood_avg <- data.frame(likelihood_rating = colMeans(new_likelihood_avg[,2:483], na.rm = TRUE))
new_likelihood_avg <- tibble::rownames_to_column(new_likelihood_avg, "image")
new <- left_join(return_log_avg, new_likelihood_avg, by = "image")
new$group = "New"
new_corr <- cor.test(new$log_rt, new$likelihood_rating, method = c("pearson"))
new_corr
##
## Pearson's product-moment correlation
##
## data: new$log_rt and new$likelihood_rating
## t = -8.2151, df = 479, p-value = 1.993e-15
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
## -0.4273951 -0.2705081
## sample estimates:
## cor
## -0.3514162
return_new_comparison <- rbind.fill(new, return)
all_change_type<- read_csv("/Users/adambarnas/Box/MetaAwareness/data/All_change_type.csv", col_types = cols())
new_changetype_boxsize_changesize_eccentricity_condensed <- left_join(new_changetype_boxsize_changesize_eccentricity_condensed, all_change_type, by = "image")
new_changetype_boxsize_changesize_eccentricity_condensed$group = "New"
return_new <- rbind.fill(all_CB_MC_changetype_boxsize_changesize_eccentricity_condensed, new_changetype_boxsize_changesize_eccentricity_condensed)
return_new <- return_new[, -c(11)]
nrow(return_new %>% distinct(workerId,.keep_all = FALSE))
## [1] 436
write.csv(return_new, "return_new.csv", row.names=FALSE)
dplyr::group_by(return_new, group) %>%
dplyr::summarise(
count = n(),
mean = mean(likelihood_rating, na.rm = TRUE),
sd = sd(likelihood_rating, na.rm = TRUE),
se = sd/sqrt(count)
)
## # A tibble: 2 x 5
## group count mean sd se
## <chr> <int> <dbl> <dbl> <dbl>
## 1 New 6600 2.98 1.37 0.0169
## 2 Original 5027 3.06 1.33 0.0187
result_7.2 <- lmer(likelihood_rating ~ (eccentricity + change_percent)*group + (1|workerId) + (1|image) + (1|stim_set), data=return_new)
summary(result_7.2)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: likelihood_rating ~ (eccentricity + change_percent) * group +
## (1 | workerId) + (1 | image) + (1 | stim_set)
## Data: return_new
##
## REML criterion at convergence: 32592
##
## Scaled residuals:
## Min 1Q Median 3Q Max
## -5.0654 -0.6298 0.0178 0.6328 4.2929
##
## Random effects:
## Groups Name Variance Std.Dev.
## image (Intercept) 6.554e-01 8.096e-01
## workerId (Intercept) 4.551e-01 6.746e-01
## stim_set (Intercept) 1.064e-10 1.032e-05
## Residual 7.648e-01 8.746e-01
## Number of obs: 11627, groups: image, 482; workerId, 436; stim_set, 4
##
## Fixed effects:
## Estimate Std. Error df t value Pr(>|t|)
## (Intercept) 2.827e+00 1.081e-01 7.153e+02 26.148 < 2e-16
## eccentricity 4.290e-04 4.558e-04 5.129e+02 0.941 0.34703
## change_percent 4.370e-02 1.592e-02 7.171e+02 2.744 0.00621
## groupOriginal 1.396e-01 7.827e-02 7.827e+02 1.784 0.07479
## eccentricity:groupOriginal -4.811e-04 2.011e-04 1.082e+04 -2.392 0.01678
## change_percent:groupOriginal -2.185e-02 7.972e-03 1.106e+04 -2.741 0.00613
##
## (Intercept) ***
## eccentricity
## change_percent **
## groupOriginal .
## eccentricity:groupOriginal *
## change_percent:groupOriginal **
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Correlation of Fixed Effects:
## (Intr) eccntr chng_p grpOrg eccn:O
## eccentricty -0.808
## chang_prcnt -0.192 -0.017
## groupOrignl -0.339 0.092 0.025
## eccntrcty:O 0.152 -0.188 0.006 -0.490
## chng_prcn:O 0.048 0.005 -0.252 -0.142 -0.022
## convergence code: 0
## boundary (singular) fit: see ?isSingular
ci(result_7.2)
## Parameter CI CI_low CI_high
## 1 (Intercept) 95 2.6153196761 3.039165e+00
## 2 eccentricity 95 -0.0004643152 1.322296e-03
## 3 change_percent 95 0.0124923531 7.491074e-02
## 4 groupOriginal 95 -0.0137602955 2.930355e-01
## 5 eccentricity:groupOriginal 95 -0.0008752597 -8.687267e-05
## 6 change_percent:groupOriginal 95 -0.0374795320 -6.228879e-03
result_8 <- lmer(log_rt ~ (likelihood_rating + eccentricity + change_percent)*group + (1|workerId) + (1|image) + (1|stim_set), data=return_new)
summary(result_8)
## Linear mixed model fit by REML. t-tests use Satterthwaite's method [
## lmerModLmerTest]
## Formula: log_rt ~ (likelihood_rating + eccentricity + change_percent) *
## group + (1 | workerId) + (1 | image) + (1 | stim_set)
## Data: return_new
##
## REML criterion at convergence: -21221.6
##
## Scaled residuals:
## Min 1Q Median 3Q Max
## -4.9305 -0.2143 -0.0166 0.1463 8.0206
##
## Random effects:
## Groups Name Variance Std.Dev.
## image (Intercept) 0.0061206 0.07823
## workerId (Intercept) 0.0049910 0.07065
## stim_set (Intercept) 0.0009816 0.03133
## Residual 0.0073978 0.08601
## Number of obs: 11612, groups: image, 481; workerId, 436; stim_set, 4
##
## Fixed effects:
## Estimate Std. Error df t value
## (Intercept) 9.436e-01 1.971e-02 5.136e+00 47.884
## likelihood_rating -2.283e-03 1.086e-03 1.153e+04 -2.103
## eccentricity 1.316e-04 4.422e-05 4.978e+02 2.977
## change_percent -4.966e-03 1.841e-03 2.800e+02 -2.698
## groupOriginal -7.234e-03 9.088e-03 1.166e+03 -0.796
## likelihood_rating:groupOriginal 2.822e-04 1.412e-03 1.107e+04 0.200
## eccentricity:groupOriginal 2.387e-06 1.979e-05 1.080e+04 0.121
## change_percent:groupOriginal 4.281e-04 7.869e-04 1.108e+04 0.544
## Pr(>|t|)
## (Intercept) 5.23e-08 ***
## likelihood_rating 0.03551 *
## eccentricity 0.00306 **
## change_percent 0.00741 **
## groupOriginal 0.42616
## likelihood_rating:groupOriginal 0.84156
## eccentricity:groupOriginal 0.90397
## change_percent:groupOriginal 0.58645
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Correlation of Fixed Effects:
## (Intr) lklhd_ eccntr chng_p grpOrg lkl_:O eccn:O
## liklhd_rtng -0.157
## eccentricty -0.418 -0.011
## chang_prcnt -0.201 -0.017 -0.031
## groupOrignl -0.210 0.239 0.077 0.020
## lklhd_rtn:O 0.083 -0.539 0.007 0.008 -0.465
## eccntrcty:O 0.078 0.025 -0.191 0.004 -0.409 -0.012
## chng_prcn:O 0.021 0.025 0.005 -0.212 -0.118 -0.006 -0.021
ci(result_8)
## Parameter CI CI_low CI_high
## 1 (Intercept) 95 9.049928e-01 9.822403e-01
## 2 likelihood_rating 95 -4.411785e-03 -1.550392e-04
## 3 eccentricity 95 4.495692e-05 2.182931e-04
## 4 change_percent 95 -8.573699e-03 -1.357878e-03
## 5 groupOriginal 95 -2.504605e-02 1.057719e-02
## 6 likelihood_rating:groupOriginal 95 -2.484617e-03 3.049017e-03
## 7 eccentricity:groupOriginal 95 -3.639685e-05 4.117155e-05
## 8 change_percent:groupOriginal 95 -1.114152e-03 1.970252e-03
return_new_comparison %>%
ggscatter(y = "log_rt", x = "likelihood_rating", color = "group", ylab = "Log CB Duration", xlab = "Likelihood of Detecting Change", palette = c("#c5050c", "#282728"), add = "reg.line", conf.int = TRUE, xlim = c(1, 5), ylim = c(0.75, 1.5), alpha = 0.5, legend = c(.1,0.9)) + theme(legend.title=element_blank())
ggsave("MS_fig_3.jpg")
return_new_corr <- return_new %>%
group_by(image,group) %>%
dplyr::summarize(likelihood_rating = mean(likelihood_rating)) %>%
spread(group,likelihood_rating)
return_new_corr %>%
ggscatter(y = "Original", x = "New", ylab = "Original Subject Rating", xlab = "New Subject Rating", add = "reg.line", conf.int = TRUE, xlim = c(1, 5), ylim = c(1, 5))