r - Download.file function does not seem to work -
i want extract data .csv online r. therefore im doing (ive created dir called "data")
fileurl <- "https://data.baltimorecity.gov/api/views/dz54-2aru/rows.csv?accesstype=download" download.file(fileurl, destfile = "./data/cameras.csv", method="curl")
it gives following error however:
warning messages: 1: running command 'curl "https://data.baltimorecity.gov/api/views/dz54- 2aru/rows.csv?accesstype=download" -o "./data/cameras.csv"' had status 127 2: in download.file(fileurl, destfile = "./data/cameras.csv", method = "curl") download had nonzero exit status
and if remove method= "curl"
error in download.file(fileurl, destfile = "./data/cameras.csv") : unsupported url scheme
any thoughts on goes wrong?
i had problem. changing method = "curl" method = "auto" worked me.
Comments
Post a Comment