Questions tagged [rcurl]

RCurl is an R package that provides an R-friendly wrapper for the libcurl C library.

RCurl is an R package that provides a wrapper for the libcurl C library (not the cURL command-line tool, ). RCurl greatly simplifies the process of interfacing R programs with web services and provides simple functions to perform common HTTP calls such as POST and GET. RCurl is cross-platform and installs necessary dependencies when it is added as an R package.

The core workhorse function in RCurl is curlPerform, which maps curl_easy_opt options almost verbatim. See listCurlOptions() for a list of arguments representing those options that can be passed to curlPerform (either directly or via other RCurl functions).

Users may also be interested in the package, which provides a further simplified wrapper around RCurl for common requests.

734 questions
10
votes
5 answers

How do I run a ldap query using R?

I want to make a query against a LDAP directory of how employees are distributed in departments and groups... Something like: "Give me the department name of all the members of a group" and then use R to make a frequency analysis, but I can not…
Luxspes
  • 6,268
  • 2
  • 28
  • 31
10
votes
2 answers

how to download a large binary file with RCurl *after* server authentication

i originally asked this question about performing this task with the httr package, but i don't think it's possible using httr. so i've re-written my code to use RCurl instead -- but i'm still tripping up on something probably related to the…
Anthony Damico
  • 5,779
  • 7
  • 46
  • 77
9
votes
2 answers

using Rcurl with HTTPs

I tried the following code in R on windows: library(RCurl) postForm("https://www.google.com/accounts/ClientLogin/", "email" = "me@gmail.com", "Passwd" = "abcd", "service" = "finance", "source" = "Test-1" ) but go the following…
Zach
  • 29,791
  • 35
  • 142
  • 201
9
votes
2 answers

Web scraping with R over real estate ads

As an intern in an economic research team, I was given the task to find a way to automatically collect specific data on a real estate ad website, using R. I assume that the concerned packages are XML and RCurl, but my understanding of their work is…
Alexis Matelin
  • 194
  • 1
  • 9
9
votes
1 answer

Error in curl::curl_fetch_memory(url, handle = handle) : Failure when receiving data from the peer

I'm trying to get lyrics from the chartlyrics API. I write an R function that works but not inside a loop. My script is: library(httr) library(RCurl) library(XML) df <- data.frame(artist = c('Led Zeppellin', 'Adele'), song = c('Rock´n roll',…
pjperez
  • 425
  • 4
  • 9
9
votes
2 answers

How can I POST a simple HTML form in R?

I'm relatively new to R programming and I'm trying to put some of the stuff I'm learning in the Johns Hopkins Data Science track to practical use. Specifically, I would like to automate the process of downloading historical bond prices from the US…
9
votes
1 answer

Unable to install Devtools package for R studio mounted on linux redhat server

I'm unable to install the devtools package in R Studio on a redhat linux server. These error messages showed up: ERROR: configuration failed for package ‘RCurl’ * removing ‘/home/xx/R/x86_64-redhat-linux-gnu-library/3.0/RCurl’ Warning in…
Ruser
  • 245
  • 3
  • 11
9
votes
3 answers

error setting certificate verify locations, install_github

I am trying to install a package from github, but I keep getting an error when I use install_github. library(devtools) install_github(repo="swirl", username="ncarchedi") Installing github repo(s) swirl/master from ncarchedi Downloading swirl.zip…
Sarah Supp
  • 93
  • 1
  • 4
9
votes
2 answers

Convert curl code into R via the RCurl package?

How I would write the following curl POST method using R and the RCurl package? curl -k -u myusername:mypassword -d '{"text":"Hello World!","level":"Noob"}' -H "Content-Type: application/json" -H "Accept: application/json"…
Jen Daleston
  • 101
  • 1
  • 1
  • 3
8
votes
2 answers

How to specify certificate, key and root certificate with httr for certificate based authentication?

I am trying to access data using httr library from server which expects certificate based authentication. I have certificate (cert.pem), key file (key.pem) and root certificate (caroot.pem) Following curl works. curl -H "userName:sriharsha@rpc.com"…
harsha
  • 933
  • 1
  • 12
  • 26
8
votes
1 answer

Rcurl: url.exists returns false when url does exist

Trying to download information from a specific web page, and although it opens fine in any browser, RCurl says it does not exists: url.exists("http://www.transfermarkt.es/liga-mx-apertura/startseite/wettbewerb/MEXA") [1] FALSE Same results when…
edufierro
  • 107
  • 1
  • 6
8
votes
1 answer

Webscraping interactive aspx websites in R

I am trying to webscrape a table from an interactive aspx webpage. I've read all of the R webscraping questions on stack and I think I am getting close, but I can't quite seem to get it. I would like to pull data from the tables produced here.…
DaedalusBloom
  • 377
  • 5
  • 12
8
votes
1 answer

Create an R package with dependencies

I'm trying to write my first R package. The functions in the package depend on the getURL() function from the RCurl package. I followed the tutorials on: http://r-pkgs.had.co.nz/…
jirikadlec2
  • 1,256
  • 1
  • 23
  • 36
8
votes
1 answer

Scraping data from tables on multiple web pages in R (football players)

I'm working on a project for school where I need to collect the career statistics for individual NCAA football players. The data for each player is in this format. http://www.sports-reference.com/cfb/players/ryan-aplin-1.html I cannot find an…
Steve Bronder
  • 926
  • 11
  • 17
8
votes
3 answers

Get website directory listing in an R vector using RCurl

I'm trying to get the list of files in a directory on a website. Is there a way to do this similar to the dir() or list.files() commands for local directory listing? I can connect to the website using RCurl (I need it because I need an SSL…
FBC
  • 993
  • 3
  • 9
  • 15
1 2
3
48 49