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
doInstall <- TRUE | |
toInstall <- c("ggplot2") | |
if(doInstall){install.packages(toInstall, repos = "http://cran.us.r-project.org")} | |
lapply(toInstall, library, character.only = TRUE) | |
ANES <- read.csv("http://www.oberlin.edu/faculty/cdesante/assets/downloads/ANES.csv") | |
ANES <- ANES[ANES$year == 2008, -c(1, 11, 17)] # Limit to just 2008 respondents, | |
head(ANES) # remove some non-helpful variables | |
# Fit several models with the same DV: |
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
rm(list=ls()) | |
# Load required libraries | |
library(RCurl) | |
library(stringr) | |
library(tm) | |
library(wordcloud) | |
library(RColorBrewer) | |
library(twitteR) | |
library(streamR) |
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
setwd("~/Dropbox/Tourism/Rdata") | |
rm(list=ls()) | |
# Libraries ==================================================================== | |
library("plyr") | |
library("reshape2") | |
# Start Merge ================================================================== | |
# See the following | |
# [1] http://goo.gl/9IojH8 | |
# [2] http://goo.gl/IP1wa9 |
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
setwd("~/Dropbox/Tourism/csv") | |
rm(list=ls()) | |
# Libraries ==================================================================== | |
library("plyr") | |
library("reshape2") | |
library("zoo") | |
# Functions ==================================================================== | |
# Delete incomplete cases | |
# http://stackoverflow.com/a/11258247 |
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 "github" library | |
library("github") | |
# Load github oauth | |
# load("~/my_oauth/my_oauth_github") | |
# Get starred by user emraher | |
starred.by.emrah <- get.repositories.starred.by.user("emraher") | |
# Find index of "rgithub" |
NewerOlder