WEAT (Table 1)

In the following we set the number of permuations to 1000. This means that, although the point estimates should agree with the paper table the p values will be relatively imprecise. To make them more precise change 1000 to a larger number and be prepared to wait a little longer. In most cases the p values is less than 0.0001, so imprecision has no real implications for statistical confidence.

First we’ll load the package and set up some graphics parameters.

WEFAT (Figure 1)


WEFAT (Figure 2)

Next we find the gender proportions for each name from the census. In the paper a gender score is constructed from the population proportions (it’s not clear how this was done or where the data came from in more detail than ‘the 1990 US census’). The replication materials bundle these as cbn_gender_name_stats_census1990

However, it’s not clear how the graphs x values come out of this data set, so we’ll use instead the gender package, which queries the US Social Security Administration to get the proportion of stated males and females with any particular first name. A version of this data is bundled with the package

We join it to res

res <- merge(res, cbn_gender_name_stats, 
             by.x = "Word", by.y = "name")

and plot the statistic against the gender proportions (converted to percentages)

ggplot(res, aes(x = 100 * proportion_female, y = S_wab, color = S_wab)) +
  geom_hline(yintercept = 0, size = 2, col = "grey") + 
  geom_point(size = 5, alpha = 0.9) +
  scale_colour_gradient2(low = "blue", mid = "yellow", high = "red", 
                         guide = FALSE) +
  xlim(0, 100) +
  ylim(-2, 2) +
  xlab("Percentage of people with name who are women") +
  ylab("Strength of association of name vector with female gender")

The correlation is

which is a tiny bit stronger than the relationship in the paper.