2

i have a link that when open automatically starts a download to a csv file, i need to intercept this csv in R and download it without let the possibility to user to choose where to download the file.

csv is generated on demand and i need to get it

4

2 回答 2

3

@ntrax,“utils”包中的“download.file”可以解决问题。

IE

download.file(url,destfile)

对于可用的许多选项,请检查 ?download.file。

于 2013-06-03T14:53:50.187 回答
1

您可以只使用read.table将 csv 文件作为数据框导入,例如:

fpe <- read.table("http://data.princeton.edu/wws509/datasets/effort.dat")

你是这个意思吗?

于 2013-06-03T13:43:09.827 回答