Assessing Racial Animus in the United States

Using Google Search Data

Elissa Colich

ecolich.github.io

 

Purpose

To assess the theory that racism has increased in the United States since the presidential race of 2016 and consequential election of Donald Trump

Hypothesis

The volume of racial Google searches increased with the advent of Donald Trump's campaign and election

Methods

  • Scrape Google Trends with R
    • gtrendsR
  • Visualize data using R and Tableau
  • Analyze data using Stata

Geography of the {N Word(s)}

Past 12 months as of 10/11/18

Illustration created from Tableau

What you can do with gtrendsR

  • Pull data:
    • By region, city, metro
    • By interest
    • By time
  • Plot data
  • Map data
  • Export data

R Notebook Created to Allow Class to Follow Along

https://github.com/ecoli14/gtrends.git​

R Notebook

  • Run code line by line
  • Run "Chunk(s)"
  • Ctrl + Shift + Enter 
  • See results below

Now let's compare two words for only the US

We know who won...what else did we learn?

Percent African American Does Not Significantly Increase {Nword} Score, but Residing in Certain Regions of the Country Does

Score by Region (2017)

West Virginia is an "outlier", Skewing the data, but Vital for Analysis of all 50 States

r=.44**

r=.57**

Time Series Analysis Results

Note: Intent of analysis is to demonstrate Stata skills versus time series analysis skill.

Webscraping with gTrendsR

By ecoli14

Webscraping with gTrendsR

  • 308