[R] Accessing data via url
Prof Brian Ripley
ripley at stats.ox.ac.uk
Fri Jan 7 09:08:28 CET 2011
?read.table says
‘file’ can also be a complete URL.
This is implemented by url(): see the section on URLs on its help
page. You haven't followed the posting guide and told us your OS, and
what the section says does depend on the OS.
On Thu, 6 Jan 2011, John Kane wrote:
> # Can anyone suggest why this works
>
> datafilename <- "http://personality-project.org/r/datasets/maps.mixx.epi.bfi.data"
> person.data <- read.table(datafilename,header=TRUE)
>
> # but this does not?
>
> dd <- "https://sites.google.com/site/jrkrideau/home/general-stores/trees.txt"
> treedata <- read.table(dd, header=TRUE)
>
> ===================================================================
>
> Error in file(file, "rt") : cannot open the connection
> In addition: Warning message:
> In file(file, "rt") : unsupported URL scheme
>
> # I can access both through a hyperlink in OOO Calc. t
> # Thanks
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-help
mailing list