PAIRWISE_GRIMMER_PATH <- here("analyses/15_validate_distance/grimmer_pairwise_distances.csv")
pairwise_tib <- read_csv(PAIRWISE_GRIMMER_PATH)
Here are the words I explored:
unique(pairwise_tib$word)
## [1] "announces" "city" "department" "important"
## [5] "jobs" "need" "support" "taxes"
## [9] "administration" "help" "bill" "tax"
## [13] "america" "safe" "act" "fight"
## [17] "message" "law" "agency" "workers"
## [21] "work" "resources" "federal" "growth"
## [25] "stimulating" "school" "announcement" "investment"
## [29] "project" "limit" "dollars" "effort"
## [33] "cut" "action" "country" "water"
## [37] "authority" "give" "control" "director"
## [41] "crisis" "urgent" "suffer" "human"
## [45] "citizenship" "measure" "debate" "committee"
## [49] "today" "program" "funding" "health"
## [53] "security" "people" "children" "service"
## [57] "local" "education" "plan" "report"
pairwise_tib %>%
group_by(word, angle) %>%
slice(1:50) %>%
count(word, angle) %>%
ggplot(aes(x = angle, y = n, fill = word)) +
geom_bar(stat = "identity") +
facet_wrap(~word, scales = "free" ) +
theme(legend.position = "none",
axis.text.x = element_text(angle = 90, vjust = 0.5, hjust=1)) +
scale_x_continuous( breaks = c(0,30, 45, 60, 90))
pairwise_tib %>%
group_by(word, angle) %>%
slice(1:50) %>%
arrange(word, angle) %>%
DT::datatable()