Skip to content
Prev 58492 / 398502 Next

Reading word by word in a dataset

Dear Andy,
Why does my 'read.table()' NOT work in this example?
I have the error, "subscript out of bounds", as you
see below. My R version is 1.9.0.
i1-apple 10$ New_York
i2-banana 5$ London
i3-strawberry 7$ Japan
colClasses=c("character","NULL","NULL"), fill=T)
Error in data[[i]] : subscript out of bounds
NULL, NULL), fill=T)
             V1  V2       V3
1      i1-apple 10$ New_York
2     i2-banana  5$   London
3 i3-strawberry  7$    Japan
NULL, NULL), fill=T)[,1]
[1] "i1-apple"      "i2-banana"     "i3-strawberry"
Cheers,

John
--- "Liaw, Andy" <andy_liaw at merck.com> wrote:
------------------------------------------------------------------------------
------------------------------------------------------------------------------