如何在twitteR中启用https支持?

时间:2015-01-25 17:54:33

标签: twitter https rcurl

我正在尝试使用R. Script中的twitteR包连接到twitter,结果如下。在Windows 8.1上运行R 3.1.2 64位。有关如何启用https的任何建议?我没有在R-help或任何其他可搜索的源上找到解决方案。

require(twitteR)
Loading required package: twitteR
Loading required package: ROAuth
Loading required package: RCurl
Loading required package: bitops
Loading required package: rjson
> cred <- OAuthFactory $ new( consumerKey = my.key, consumerSecret = my.secret, requestURL =' https:// api.twitter.com/ oauth/ request_token', accessURL =' https:// api.twitter.com/ oauth/ access_token', authURL =' https:// api.twitter.com/ oauth/ authorize')
> cred$handshake(cainfo = "C:/users/john/documents/twitter/cacert.pem")
Error in function (type, msg, asError = TRUE)  : 
  Protocol " https" not supported or disabled in libcurl

1 个答案:

答案 0 :(得分:0)

requestURL和以下的网址是用单引号指定的。当单引号被替换为双引号并删除空格时,该功能在Windows上起作用。