This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## install these if not already | |
pkgs <- c("remotes", "syuzhet", "tfse", "rtweet", "ggplot2", "dplyr", "tidyr") | |
if (length(pkgs <- pkgs[!pkgs %in% installed.packages("remotes")]) > 0) { | |
install.packages(pkgs) | |
} | |
## install from github | |
remotes::install_github("mkearney/dataviz") | |
remotes::install_github("mkearney/dict") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## load rtweet | |
library(rtweet) | |
## store bounding box coordinates for state of nevada | |
nv <- c(-120.00647, 35.00186, -114.03965, 42.00221) | |
## initialize output vector and Midwestern 'ope' counter | |
s <- list() | |
ope <- 0L |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#------------------------------------------------------------------------------# | |
# API KEYS/SECRETS | |
#------------------------------------------------------------------------------# | |
# twitter keys - these are fake replace these with your twitter keys found | |
# at https://developer.twitter.com/en | |
# be careful with these – do not share or save to cloud. use environment | |
# variables, follow best practices, don't be careless :) | |
consumer_key = "IYWxHaPxjpalssdfkj" | |
consumer_secret = "Cyx8OqcOtniCe63ZmaPxvvq6HvstV6PuS1AjwY9g1awnbaIUp4" |
OlderNewer