Skip to content

read.table

2 messages · Ricardo Gonçalves, Brian Ripley

#
Dear All,

A beginner again:
I am using the command: x<-read.table("a:\xx.dat", headre=TRUE) 
and I receive the error message:
Error in read.table("a:xx.dat", header = TRUE) : 
        all rows must have the same length.
My data matriz includes 62 variables by 131 countries.
There are some problem in this parameters?

Thanks
Rick.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://stat.ethz.ch/pipermail/r-help/attachments/20010617/010ad3f2/attachment.html
#
On Sun, 17 Jun 2001, [iso-8859-1] Ricardo Gonçalves wrote:

            
The answer is the same: do read the R Data Import/Export Manual.

But immediately:

You need a:/xx.dat or a:\\xx.dat (do read the FAQs)

Which version of R is this? The latest released version, 1.3.0,
given you a meesage about what the row numbers were before that message,
and you should heed (and quote) all the messages you get.

You probably need to set a separator, e.g. sep="\t".

I hope your 62 variables are all on one line, as read.table cannot
read multi-line records, as the help page clearly states.

    file: the name of the file which the data are to be read from. Each
          row of the table appears as one line of the file.  If it does