[R] using wildcards in download.file?

MacQueen, Don macqueen1 at llnl.gov
Fri Apr 13 18:19:49 CEST 2012


If you take a thorough look at the help page for download.file, and follow
its advice, you may find a solution.

Hint:
The help page for download.file says,

-- quote --
The function 'download.file' can be used to download a single file
     as described by 'url' from the internet and store it in
     'destfile'.
-- end quote --

I'd say that makes it pretty clear the answer is no.

Further on in the help page in the "See Also" section it refers to another
package.

Hint:
A help page for one of the functions in that packages says,
-- quote --
# FTP
       # Download the files within a directory.
 
-- end quote --


which looks promising.


-- 
Don MacQueen

Lawrence Livermore National Laboratory
7000 East Ave., L-627
Livermore, CA 94550
925-423-1062





On 4/12/12 2:07 PM, "jtang at mappi.helsinki.fi" <jtang at mappi.helsinki.fi>
wrote:

>Hi,
>Do you know whether it is possible to use wildcards in download.file()?
>For example:
>url = "ftp://abc.com/*.*" # to download all the files in the ftp folder
>download.file(url,destfile=...) # does not work, any solutions?
>
>Thanks!
>
>JIng
>
>______________________________________________
>R-help at r-project.org mailing list
>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.



More information about the R-help mailing list