Re: [R] reading data

About this list Date view Thread view Subject view Author view Attachment view

From: JWDougherty (jwdougherty@mcihispeed.net)
Date: Thu 06 May 2004 - 11:35:50 EST


Message-id: <200405051835.50854.jwdougherty@mcihispeed.net>

On Wednesday 05 May 2004 03:37, Margarida Júlia Rodrigues Igreja wrote:
> Hello,
> I´m trying to read data from a text file but i can´t
>
> When i print:
> > a<-read.table(file="C:/dados10.txt")
>
> The next error appears:
> Error in file(file, "r") : unable to open connection
> In addition: Warning message:
> cannot open file `C:/dados10.txt'
> Can you help me?
>
Margarida,

It depends on a number of things. First, is the "C:" a local harddrive (on
the machine you are using) non-local. Second, "C:\" is a DOS/Windows
construct and the slash particular will be interpreted differently under a
*nix system than under DOS. *nixes use the "/" instead. "C:/dados.txt"
would seem to indicate the "dados.txt" file in the root directory of a DOS or
Windows machine. SO, first be certain on which machine, and on which drive,
and in which directory on that machine your file is located. After that, if
the file is on a non-local drive, then be certain that the drive and
directory are mounted and readable from the machine on which you are running
R. Also, you must determine if you have read rights for the drive,
directory, and file. If you don not, you need to have the administrator or
file owner grant them to you. Once these steps are done, then by providing
are the mounted alias of the drive, directory and filename, you should be
good. Otherwise, you should be able to copy the data to your working
directory.

Good luck,
John Dougherty

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


About this list Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.3 : Mon 31 May 2004 - 23:05:07 EST