Re: [R] Recursive file Download from FTP Error

2013-01-27 Thread Peter Maclean
I am trying to download multiple files from a ftp. However, I get this error after downloading several files: cannot open URL ''. The stopage occurs randomly; can be after the 10th  or 30th etc. The code I am using is:   # #rm(list=ls(all=TRUE)) require(RCurl) require("R.u

Re: [R] Recursive file Download from FTP

2013-01-16 Thread Rui Barradas
Hello, You have an extra "argument" to getURL that is _not_ an argument: ftp://ftp.use.epsv/ To get the list of files just do url <- "ftp://ftp.cpc.ncep.noaa.gov/fews/AFR_CLIM/ARC2/DATA/1985/"; filenames <- getURL(url, dirlistonly = TRUE) fn <- unlist(strsplit(filenames, "\r\n")) # To download

Re: [R] Recursive file Download from FTP

2013-01-16 Thread Peter Maclean
  I want to download and unzip many files from the FTP and create variables for year, month, and day for each file based on the naming mechanism. I am stack with the following lines and any help will be highly appreciated. I want to create a spreadsheet file with lat lon and estimate as headers.

Re: [R] Recursive file Download from FTP

2013-01-16 Thread Peter Maclean
I want to download and unzip many files from the FTP and create variables for year, month, and day for each file based on the naming mechanism. I am stack with the following lines and any help will be appreciated.   library(RCurl) # Download the files for 1985. url = "ftp://ftp.cpc.ncep.noaa.gov