I'm trying to retrieve all the tweets from a specific users timeline (donald trump for example) using the userTimeline() function from the twitteR package. My problem is that the function is only returning 469 tweets, as opposed to the 3200 I've specified.
I saw this post of a similar problem, where the answer suggested that the Twitter API only returns tweets from the past week. But in my data, I can see tweets that were created nearly 3 months ago. Does anyone know a way that I can get the max number of tweets possible? If not, does anyone know why I'm getting tweets that were created longer than a week ago?
You can see my code below:
library(devtools)
library(httr)
install_github("twitteR", username = "geoffjentry")
library(twitteR)
setup_twitter_oauth(...."details")
mht=userTimeline('realDonaldTrump',n=3200)
tweets.df <- do.call(rbind, lapply(mht, as.data.frame))
Running this code will get me 469 tweets from his most recent to the 2016-08-12. I want to get as many tweets as possible from as a long a period as I can get.