library(tidyverse)
## ── Attaching packages ───────────────────────────────────────────────────────────────────────── tidyverse 1.2.1 ──
## ✔ ggplot2 3.1.0 ✔ purrr 0.2.5
## ✔ tibble 2.1.1 ✔ dplyr 0.8.0.1
## ✔ tidyr 0.8.2 ✔ stringr 1.3.1
## ✔ readr 1.1.1 ✔ forcats 0.3.0
## ── Conflicts ──────────────────────────────────────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag() masks stats::lag()
Scale:
Strongly disagree
Disagree
Tend to disagree
Neither agree nor disagree
Tend to agree
Agree
Strongly agree
search_trust <- read_csv("data/trust/search-news-trust.csv")
## Parsed with column specification:
## cols(
## .default = col_integer(),
## question = col_character(),
## question_choice = col_character()
## )
## See spec(...) for full column specifications.
# stack gender
search_trust_gender <- search_trust %>% select(question, question_choice, male, female) %>% gather(gender, count, male, female)
# stack age
search_trust_age <- search_trust %>% select(question, question_choice, `18-24`:`65+`) %>% gather(age, count, `18-24`:`65+`)
#write_csv(search_trust_age, "data/trust/age-searchtrust-split.csv")
Scale: 1-10
Options:
Fox News
CNN
NBC/MSNBC News
ABC News
CBS News
Yahoo! News
Local television news
New York Times
Washington Post
HuffPost (Huffington Post)
Buzzfeed News
NPR News
Breitbart
Wall Street Journal
Vice News
brand_trust <- read_csv("data/trust/brand-trust-distrust.csv")
## Parsed with column specification:
## cols(
## .default = col_integer(),
## trust_level = col_character(),
## brand = col_character()
## )
## See spec(...) for full column specifications.
# stack gender
brand_trust_gender <- brand_trust %>% select(trust_level, brand, male, female) %>% gather(gender, count, male, female)
# stack age
brand_trust_age <- brand_trust %>% select(trust_level, brand, `18-24`:`65+`) %>% gather(age, count, `18-24`:`65+`)
Agree with statements:
Technology companies (e.g. Facebook and Google) should do more to make it easier to separate what is real and what is fake on the internet
Media companies and journalists should do more to make it easier to separate what is real and what is fake on the internet
The Government should do more to make it easier to separate what is real and fake on the internet
Scale:
Strongly disagree
Disagree
Tend to disagree
Neither agree nor disagree
Tend to agree
Agree
Strongly agree
misinfo_trio <- read_csv("data/misinfo/tech-media-gov.csv")
## Parsed with column specification:
## cols(
## .default = col_integer(),
## entity = col_character(),
## question_choice = col_character()
## )
## See spec(...) for full column specifications.
# stack gender
misinfo_gender <- misinfo_trio %>% select(entity, question_choice, Male, Female) %>% gather(gender, count, Male, Female)
# stack age
misinfo_age <- misinfo_trio %>% select(entity, question_choice, `18-24`:`65+`) %>% gather(age, count, `18-24`:`65+`)
# separate by age groups
misinfo_age_tech <- misinfo_age %>% filter(entity == "Technology companies")
#write_csv(misinfo_age_tech, "data/misinfo/trio-tech.csv")
misinfo_age_media <- misinfo_age %>% filter(entity == "Media companies and journalists")
#write_csv(misinfo_age_media, "data/misinfo/trio-media.csv")
misinfo_age_gov <- misinfo_age %>% filter(entity == "Government")
#write_csv(misinfo_age_gov, "data/misinfo/trio-gov.csv")