Hello
I am trying to do tweet analysis for my educational project with Twitter API and RStudio. I created my developer account and created an app. When I’m trying to upgrade my account to Search Tweets: Full Archive / Sandbox, it says me “Current Subscription”. But when I am trying to find tweets, I can only see the tweets in 2019. When I tried to find since=2017, there was no tweet in RStudio. Can you help me?
This is my RStudio Code
library(twitteR)
setup_twitter_oauth(api_key,api_secret,access_token,access_token_secret)
tweets ← searchTwitter(‘antalya’,n=1000,since=‘2017-01-01’)
tweetsdf ← twListToDF(tweets)
@Hamza Hamza bey, yardımcı olabilirseniz çok sevinirim 
Thank you
twitteR is no longer maintained, so i’d recommend switching to rtweet GitHub - mkearney/rtweet: 🐦 R client for interacting with Twitter's [stream and REST] APIs
Neither of those support the Premium API though - so you’ll have to make and auth your own calls with httr or something similar Premium search APIs | Docs | Twitter Developer Platform
You should use another way to deal with Premium API when Extract data
because Premium API get the data as json code
I think this will answer you’r question
First, thank you for your answer 
But with rtweet, I can only returns data from the past 6-9 days. But I should do more than this 
I tried to read your developer.twitter link but I did not understand what should I do, because I am beginner for Rstudio
Thank you !
The 6-9 day limit on search results is due to Twitter’s own limits, nothing to do with the library you’re using - there is no way around it. Also, what you see on the web / mobile twitter app search is a completely different search infrastructure and shouldn’t be compared.
You can get results as old as 30 days, or the entire archive from 2006 using Search API | Twitter API | Docs | Twitter Developer Platform (but this endpoint is not used by any R library i know of) If you’re just starting out with R implementing your own calls to the Premium APIs might take a bit of effort, alternatively you can try this python implementation: GitHub - twitterdev/search-tweets-python: Python client for the Twitter 'search Tweets' and 'count Tweets' endpoints (v2/Labs/premium/enterprise). Now supports Twitter API v2 /recent and /all search endpoints.
Thank you for your answer again. In this case I will try to this my project with python. But I’m beginner for python too. Do you think can I handle this problem with python easily ?
That depends entirely on what you want to do, but remember that you can always ingest tweet data in python, save it as JSON or CSV and continue to do analysis in R if that makes things easier.
3 Likes
Thank you very much sir for all your help 
3 Likes
system
Closed
#9
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.