[R] Problem with downloading workspace file from a web address

Uwe Ligges ligges at statistik.tu-dortmund.de
Sun Sep 27 17:57:14 CEST 2009



Paul Smith wrote:
> Dear All,
> 
> To load a previously saved workspace, one can do the following:
> 
> load("/path/to/the/saved/workspace/file")
> 
> However, if the path to the saved workspace file is a web address, one
> gets the following error:
> 
> «Error in readChar(con, 5L, useBytes = TRUE) : cannot open the connection
> In addition: Warning message:
> In readChar(con, 5L, useBytes = TRUE) :
>   cannot open compressed file
> 'http://phhs80.googlepages.com/workspace20090922', probable reason 'No
> such file or directory'»
> 
> To circumvent this problem, one can download the saved workspace file
> to a local folder with download.file() and the option
> 
> mode="wb"
> 
> active.
> 
> My question is: Should not load() have the same mode option so that
> everything could be done only with load() (and not with two
> instructions: downaload.file() and load())?


How did you try?

Does load(url("http://phhs80.googlepages.com/workspace20090922")) work 
for you?

Uwe Ligges


> Thanks in advance,
> 
> Paul
> 
> ______________________________________________
> 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