I'm attempting to download zip files directly from the Kaggle space in my R code itself. Unfortunately, it's not working out right. Here's what's happening:
For the San Francisco Crime Data set at https://www.kaggle.com/c/sf-crime/data
Take the first data set: test.csv.zip: https://www.kaggle.com/c/sf-crime/download/test.csv.zip
I'm using R code:
download.file(url='https://www.kaggle.com/c/sf-crime/download/test.csv.zip', destfile = 'test.zip',method = 'curl')
In place of the original 18.75MB file, R only downloads a 183byte file.
Session output:
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0100 183 100 183 0 0 665 0 --:--:-- --:--:-- --:--:-- 667
What am I doing wrong?
Thanks in advance, Rahul
<html><head><title>Object moved</title></head><body> <h2>Object moved to <a href="/account/login?ReturnUrl=%2fc%2fsf-crime%2fdownload%2ftest.csv.zip">here</a>.</h2> </body></html>