Skip to content

Instantly share code, notes, and snippets.

@csgallego
Created January 31, 2014 05:35
Show Gist options
  • Select an option

  • Save csgallego/8727055 to your computer and use it in GitHub Desktop.

Select an option

Save csgallego/8727055 to your computer and use it in GitHub Desktop.
#I am creating “POTUS” that gives me every visitors who visited the President of the United States.
POTUS=visits[visitee==“potus ”,]
#I’m marking sure I include all the versions of POTUS possible:
POTUS = visits[ tolower(visits$visitee_namefirst) == "potus" | tolower(visits$visitee_namelast) == "potus" ,]
#We created a subsrting of those who visited POTUS on June 5th:
substr(POTUS$APPT_START_DATE, 1,5)
#Let’s make a histogram:
hist(POTUS$time$yday,breaks=1000)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment