[R] write.table error
ripley at stats.ox.ac.uk
Fri Jul 5 08:10:27 CEST 2002
You gien us nothing to reproduce this with, and other examples work.
R does have debugging tools that would allow you to investigate this.
In particular, as rownames<- is not actually used in write.table,
the result of traceback() is the minimum that is needed when reporting an
Just one possbility: it should be `row.names=FALSE', and if you had a
variable called F this might be the explanation.
On 5 Jul 2002, Ross Darnell wrote:
> I am getting the following when trying to write a dataframe to a file.
> I would appreciate any advice to where the problem lies.
> Ross Darnell
> > write.table(all,file="agree.csv",row.names=F)
> Error in "rownames<-"(*tmp*, value = row.names(x)) :
> length of dimnames not equal to array extent
> > is.data.frame(all)
>  TRUE
> > dim(all)
>  854 18
> > length(row.names(all))
>  854
> > R.version
> platform i686-pc-linux-gnu
> arch i686
> os linux-gnu
> system i686, linux-gnu
> major 1
> minor 5.0
> year 2002
> month 04
> day 29
> language R
> 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
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 272860 (secr)
Oxford OX1 3TG, UK Fax: +44 1865 272595
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