Questions tagged [rtweet]

Questions about the R package for interacting with Twitter's API

An implementation of calls designed to extract and organize Twitter data via Twitter’s REST and stream API’s. Functions formulate GET and POST requests and convert response objects to more user friendly structures, e.g., data frames or lists. Specific consideration is given to functions designed to return tweets data from searches, streams, and timelines and user ids from friends and followers lists. More info: rtwitter reference manual.

198 questions
1
vote
0 answers

How to pull tweets with only 1 cashtag?

I am working on a project where I am pulling in Tweets using a cash tag and performing sentiment analysis on those tweets. The issue I am having is the tweets can have more than one cashtag and I want to limit to just one. I am using the R package…
8nracing
  • 11
  • 2
1
vote
2 answers

Search_tweets() (rtweet package) does not return all expected columns

I'm using the rtweet package and it's not returning the database with all columns with the search_tweets() function. The database has only 35 columns and no columns "screen_name" and "mentions_screen_name". Please how to get the rest of the columns?…
1
vote
1 answer

Filter tweets for a given account or ID, but not having to account for tweets published from this account in R?

I would like to extract tweets with R for any determined account. Is that possible? I have tried with: library(rtweet) api_key <- "xxxxxxxxxxxxxxxxxxxxxxxxxx" api_secret_key <- "xxxxxxxxxxxxxxxxxxxxxxxxxx" access_token =…
1
vote
1 answer

rtweet - Warning: 32 - Could not authenticate you

I notice a few people have encountered issues with rtweet authorization. I followed this vignette which assumes people are familiar with authentication protocols. Newbies such as myself, struggle with this. vignette("auth", package = "rtweet")` I…
aterhorst
  • 625
  • 4
  • 14
1
vote
0 answers

Twitter streaming in R, "Error in vector("list", ntimes) : invalid 'length' argument"?

I am trying to steam some tweets. The code is as follows; Supplier_List <- data.frame(companies = c("company1","company2","company3")) Streamed_Tweets <- purrr::map_df(Supplier_List$companies, ~{ search_tweets2(.x, retryonratelimit =…
jay
  • 47
  • 3
1
vote
1 answer

academictwitteR - Error in make_query(url = endpoint_url, params = params, bearer_token = bearer_token, : something went wrong. Status code: 403

I have just received an Academic Twitter Developer privileges and am attempting to scrape some tweets. I updated RStudio, regenerated a new bearer token once I got updated Academic Twitter access, and get_bearer() returns my new bearer token.…
1
vote
0 answers

Unable to access certain endpoints even though I have Twitter Elevated API

I have managed to receive my approval for Twitter Elevated API. However, when I try to run the code on R, I still receive this error message. Anybody knows what I am potentially doing wrong or if it will take a while for the system to update this…
1
vote
0 answers

Get replies to a specific Twitter user?

I'm currently having trouble collecting Twitter-replies to a specific Twitter-user. I'm not trying to collect replies to a specific tweet, just the user in general (i.e. all replies to X number of tweets from a user). I'm using the rtweet package…
StatGuy25
  • 15
  • 3
1
vote
1 answer

Rtweet accounts of interest

I need to get tweets for a research project using R and specifically the package rtweet. I have my premium Twitter API ready and I can get tweets as data frames but what I cannot do is use the accounts of interests functions. tweets <-…
Beyzanur
  • 11
  • 2
1
vote
0 answers

Error accessing tweets using rweet pacakge in R

Below is my R script for fetching a particular hashtag trending on twitter. I do have the APIs, and the access tokens. library(rtweet) api <- " " api_secret <- " " bearerToken <- " " accessToken <- " " secretaccessToken <- " " appname <- " " #…
andy
  • 1,947
  • 5
  • 27
  • 46
1
vote
0 answers

Extracting Tweets that have only one hashtag dobale

I was able to run the code below to extract tweets using the hashtag "rstats". Now is there a way to extract tweets for ONLY '#rstats". So that '#rstats' is the only hashtag in the tweet? I want to scrape tweets that have ONE and only ONE specific…
FredNina
  • 11
  • 3
1
vote
0 answers

Packages for looking up Twitter data

I'm looking for a package that can look up Tweets by date. I'm currently using rtweets where I can look up the last Tweets (18,000 at a time) with certain hashtags or users. But I want to look up Tweets within a range of dates. Any idea of a good…
Heather_B
  • 11
  • 2
1
vote
0 answers

parse_stream doesnt seem to convert my json file to a data frame. The result it gives me is null

I am tryin to use parse_stream to convert a json file to a data frame, it doesnt create the data frame instead it shows up under values in r-studio and it is null. library(rtweet) library(rjson) stream_tweets(q='brasil, brazil',timeout =…
lams
  • 352
  • 1
  • 10
1
vote
0 answers

RTweet new lookup_users continued excess error

I was using R's RTweet lookup_users to successfully pull data on 6 IDs test<-c("ID1","ID2","ID3","ID4","ID5","ID6") detail_followers <- lookup_users(users=test, parse=TRUE, …
user72847
  • 23
  • 5
1
vote
0 answers

Users tagged in image (Twitter API)

Using Twitter API, is there any way to find out which users are tagged in an image attached to a Tweet? For instance, this Tweet's accompanying media has 10 users tagged (see the red circle): I use R's rtweet-package. My use of…
anpami
  • 760
  • 5
  • 17
1 2
3
13 14