[R] reading in vectors from text files

Rashmi Mathur rashmimathur at shaw.ca
Mon Mar 21 07:12:52 CET 2005


Hello,

I am trying to read in a file of data using read.table(), in which the
data in one column is vectors.

The format of the file is as follows -


FirstName	LastName	no.Children		children.ages
Sally		James		3			c(3,5,7)
John		Smith		2			c(13,16)
Betsy		Harold	6			c(2,5,8,12,15,17)


How do I specify that the children.ages column contains vector data, and
that each vector is of a different length when reading in this text
file?

Thanks in advance,
Rashmi




More information about the R-help mailing list