Quantcast

Twitter Analytics Using streamR - subscript out of bounds

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Twitter Analytics Using streamR - subscript out of bounds

Raquel D.
can someone help me? How fix this error?

My code:

library("ROAuth")
library("streamR")
library("rjson")
library("twitteR")

apiKey <- "xxx"
apiSecret <- "xxx"
accessToken <- "xxx"
accessSecret <- "xxx"
requestURL <- "https://api.twitter.com/oauth/request_token"
accessURL <- "https://api.twitter.com/oauth/access_token"
authURL <- "https://api.twitter.com/oauth/authorize"

my_oauth <- OAuthFactory$new(consumerKey = apiKey, consumerSecret = apiSecret,
                         requestURL = requestURL, accessURL = accessURL, authURL = authURL)


my_oauth$handshake(cainfo = system.file("CurlSSL", "cacert.pem", package = "RCurl"))


save(my_oauth, file = "my_oauth.Rdata")

load("my_oauth.Rdata")
filterStream("tweets.json", track = "kinoplex", timeout = 180,
         oauth = my_oauth)


tweets.df <- parseTweets("tweets.json", simplify = TRUE)

ERROR: tweets.df <- parseTweets("tweets.json", simplify = TRUE) Error in results.list[[1]] : subscript out of bounds


        [[alternative HTML version deleted]]

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Twitter Analytics Using streamR - subscript out of bounds

Jeff Newmiller
I am no expert, but I think any attempt to save your OAuth data is doomed to fail. Solution is don't do it.
--
Sent from my phone. Please excuse my brevity.

On April 18, 2017 11:38:10 AM PDT, "Raquel D." <[hidden email]> wrote:

>can someone help me? How fix this error?
>
>My code:
>
>library("ROAuth")
>library("streamR")
>library("rjson")
>library("twitteR")
>
>apiKey <- "xxx"
>apiSecret <- "xxx"
>accessToken <- "xxx"
>accessSecret <- "xxx"
>requestURL <- "https://api.twitter.com/oauth/request_token"
>accessURL <- "https://api.twitter.com/oauth/access_token"
>authURL <- "https://api.twitter.com/oauth/authorize"
>
>my_oauth <- OAuthFactory$new(consumerKey = apiKey, consumerSecret =
>apiSecret,
>     requestURL = requestURL, accessURL = accessURL, authURL = authURL)
>
>
>my_oauth$handshake(cainfo = system.file("CurlSSL", "cacert.pem",
>package = "RCurl"))
>
>
>save(my_oauth, file = "my_oauth.Rdata")
>
>load("my_oauth.Rdata")
>filterStream("tweets.json", track = "kinoplex", timeout = 180,
>         oauth = my_oauth)
>
>
>tweets.df <- parseTweets("tweets.json", simplify = TRUE)
>
>ERROR: tweets.df <- parseTweets("tweets.json", simplify = TRUE) Error
>in results.list[[1]] : subscript out of bounds
>
>
> [[alternative HTML version deleted]]
>
>______________________________________________
>[hidden email] mailing list -- To UNSUBSCRIBE and more, see
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide
>http://www.R-project.org/posting-guide.html
>and provide commented, minimal, self-contained, reproducible code.

______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Twitter Analytics Using streamR - subscript out of bounds

Raquel D.
I have tried this. Same error.


Att;


________________________________
De: Jeff Newmiller <[hidden email]>
Enviado: ter´┐Ża-feira, 18 de abril de 2017 19:23
Para: [hidden email]; Raquel D.; [hidden email]
Assunto: Re: [R] Twitter Analytics Using streamR - subscript out of bounds

I am no expert, but I think any attempt to save your OAuth data is doomed to fail. Solution is don't do it.
--
Sent from my phone. Please excuse my brevity.

On April 18, 2017 11:38:10 AM PDT, "Raquel D." <[hidden email]> wrote:

>can someone help me? How fix this error?
>
>My code:
>
>library("ROAuth")
>library("streamR")
>library("rjson")
>library("twitteR")
>
>apiKey <- "xxx"
>apiSecret <- "xxx"
>accessToken <- "xxx"
>accessSecret <- "xxx"
>requestURL <- "https://api.twitter.com/oauth/request_token"
>accessURL <- "https://api.twitter.com/oauth/access_token"
>authURL <- "https://api.twitter.com/oauth/authorize"
>
>my_oauth <- OAuthFactory$new(consumerKey = apiKey, consumerSecret =
>apiSecret,
>     requestURL = requestURL, accessURL = accessURL, authURL = authURL)
>
>
>my_oauth$handshake(cainfo = system.file("CurlSSL", "cacert.pem",
>package = "RCurl"))
>
>
>save(my_oauth, file = "my_oauth.Rdata")
>
>load("my_oauth.Rdata")
>filterStream("tweets.json", track = "kinoplex", timeout = 180,
>         oauth = my_oauth)
>
>
>tweets.df <- parseTweets("tweets.json", simplify = TRUE)
>
>ERROR: tweets.df <- parseTweets("tweets.json", simplify = TRUE) Error
>in results.list[[1]] : subscript out of bounds
>
>
>       [[alternative HTML version deleted]]
>
>______________________________________________
>[hidden email] mailing list -- To UNSUBSCRIBE and more, see
>https://stat.ethz.ch/mailman/listinfo/r-help
>PLEASE do read the posting guide
>http://www.R-project.org/posting-guide.html
>and provide commented, minimal, self-contained, reproducible code.
        [[alternative HTML version deleted]]


______________________________________________
[hidden email] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Loading...