Let’s try looking at the order? Question: are people in the different conditions more/less likely to list the types in a different order? Simple way to look at it is to compare the mean ranks of taxonomic, thematic, etc. If half the people in a condition put thematic as 1 and half as 3, this would show up as having the same mean as a group in which everyone put it as rank 2. I doubt that’s the case, but an easy way to check is to look at the variability (or just plot the distributions of ranks to make sure they’re similar in each group).


Read in data

# tdcs data
d.all = read.csv("../data/labDataPlusNorms.csv") %>%
  rename(condition = electrode,
         association.num = mention) %>%
  select(1:4,7,9:19,21,22) %>%
  mutate(condition = fct_recode(condition, "sham" = "na"))

semantic categories

Rank order distributions as a function of condition and category type.

cat.dists = d.all %>%
  select(-hyponym, -hypernym, -meronymPart, -meronymSubstance, -taxonomic, -synonym) %>% 
  gather("category", "present", 6:12) %>%
  filter(present == 1)

ggplot(cat.dists, aes(x = association.num,group = condition, fill = condition)) +
  geom_histogram(position = "dodge", binwidth =1) +
  facet_wrap(~category)

ggplot(cat.dists, aes(x = association.num,group = condition, fill = condition)) +
  geom_density(alpha = .2) +
  facet_wrap(~category)

Nothing about these distributions looks too anomalous?

Mean

cat.ms = cat.dists %>%
  group_by(condition, category) %>%
  multi_boot_standard(column = "association.num", na.rm = T)

  ggplot(cat.ms, aes(fill = condition, y = mean, x = category)) +
  ylab("mean rank order") +
  geom_bar(stat = "identity", position = "dodge") +
  geom_linerange(aes(ymax = ci_upper, ymin=ci_lower),
                 position = position_dodge(width = .9)) 

Median

cat.ms = cat.dists %>%
  group_by(condition, category) %>%
  summarize(median = median(association.num))
  #multi_boot_standard(column = "association.num", na.rm = T, empirical_function = "median")

  ggplot(cat.ms, aes(fill = condition, y = median, x = category)) +
  ylab("median rank order") +
  geom_bar(stat = "identity", position = "dodge") 

Given that there are condition differences in number of associations, let’s look at first four associates only.

cat.ms.filtered = cat.dists %>%
  group_by(condition, category) %>%
  filter(association.num < 5) %>%
  multi_boot_standard(column = "association.num", na.rm = T)

  ggplot(cat.ms.filtered, aes(fill = condition, y = mean, x = category)) +
  ylab("mean rank order") +
  geom_bar(stat = "identity", position = "dodge") +
  geom_linerange(aes(ymax = ci_upper, ymin=ci_lower),
                 position = position_dodge(width = .9)) 

Median

cat.ms.filtered = cat.dists %>%
  group_by(condition, category) %>%
  filter(association.num < 5)%>%
  summarize(median = median(association.num))

ggplot(cat.ms.filtered, aes(fill = condition, y = median, x = category)) +
  ylab("median rank order") +
  geom_bar(stat = "identity", position = "dodge") 

parts of speech

d.pos = d.all %>% 
        left_join(parts_of_speech, by=c("target" = "word")) %>%
  filter(!is.na(pos))

ggplot(d.pos, aes(x = association.num, group = condition, fill = condition)) +
  geom_histogram(position = "dodge", binwidth =1)  +
  facet_wrap(~pos)

ggplot(d.pos, aes(x = association.num, group = condition, fill = condition)) +
  geom_density(alpha = .2) +
  facet_wrap(~pos)

Mean

pos.ms = d.pos %>%
  filter(association.num < 5) %>%
  group_by(condition, pos) %>%
  multi_boot_standard(column = "association.num", na.rm = T)

ggplot(pos.ms, aes(fill = condition, y = mean, x = pos)) +
  ylab("mean rank order") +
  geom_bar(stat = "identity", position = "dodge") +
  geom_linerange(aes(ymax = ci_upper, ymin=ci_lower),
                 position = position_dodge(width = .9)) 

Median

pos.ms = d.pos %>%
  filter(association.num < 5) %>%
  group_by(condition, pos)%>%
  summarize(median = median(association.num))

ggplot(pos.ms, aes(fill = condition, y = median, x = pos)) +
  ylab("median rank order") +
  geom_bar(stat = "identity", position = "dodge") 

Collapse across nouns/verbs

d.pos = d.pos %>%
  mutate(pos2 = fct_collapse(pos,
         noun = c("Noun", "Plural"),
         verbadj = c("Verb (intransitive)", "Verb (transitive)",
                    "Verb (usu participle)", "Adjective"),
         other = c("Adverb", "Interjection", "Definite Article",
                   "Preposition", "Pronoun")))

ggplot(d.pos, aes(x = association.num, group = condition, fill = condition)) +
  geom_density(alpha = .2) +
  facet_wrap(~pos2)

pos.ms = d.pos %>%
  filter(association.num < 5) %>%
  group_by(condition, pos2) %>%
  multi_boot_standard(column = "association.num", na.rm = T)

ggplot(pos.ms, aes(fill = condition, y = mean, x = pos2)) +
  ylab("mean rank order") +
  geom_bar(stat = "identity", position = "dodge") +
  geom_linerange(aes(ymax = ci_upper, ymin=ci_lower),
                 position = position_dodge(width = .9))