[R] read table problem

From: Chua Tock Hing <chua.tock.hing_at_artsci.monash.edu.my>
Date: Fri 24 Feb 2006 - 18:19:22 EST


Hi  

I have a file saved in R, named agrexp.Rdata, shown below  

> agrdata

  fert yield

1 25 84

2 50 80

3 75 90

4 100 154

5 125 148  

If I double clicked on this file, the data is displayed without problem.

However if I tried to import using:

> agrdata<-read.table("agrexp.Rdata") or

> agrdata<-read.table("agrexp.Rdata",header=TRUE) or

> agrdata<-read.table("agrexp.Rdata",header=TRUE,row.names=1) or

> agrdata<-read.table("agrexp.Rdata",sep="")
 

I get an error message

"Warning message:

incomplete final line found by readTableHeader on 'agrexp.Rdata'"  

or if I used:

> data(agrexp)

I get Warning message:

data set 'agrexp' not found in: data(agrexp)  

Can anybody please help? I am a new user!  

Thank you  

CHUA TH         [[alternative HTML version deleted]]



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Fri Feb 24 18:29:51 2006

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:42:45 EST