[R] Problem with read.table and scan
Uwe Ligges
ligges at statistik.uni-dortmund.de
Mon Sep 24 21:17:49 CEST 2001
"Scott, Uriel" wrote:
>
> The R version is 1.3.1 and the following is an example of the problem:
>
> > air <- read.table("air.data",header=TRUE)
> Error in file(file, "r") : cannot open file `air.data'
Just specify the location completely, e.g.:
read.table("c:/my_path_to_the_file/air.data", header=TRUE)
R looks in your current working directory for files without specified
path.
You get the current working directory by
getwd()
Uwe Ligges
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list