[R] data import problem

2006-03-08 Thread Arne.Muller
Dear All, I'm trying to read a text data file that contains several records separated by a blank line. Each record starts with a row that contains it's ID and the number of rows for the records (two columns), then the data table itself, e.g. 123 5 89.17911.1024 90.57351.1024 92.5666

Re: [R] data import problem

2006-03-08 Thread Philipp Pagel
On Wed, Mar 08, 2006 at 12:32:28PM +0100, [EMAIL PROTECTED] wrote: I'm trying to read a text data file that contains several records separated by a blank line. Each record starts with a row that contains it's ID and the number of rows for the records (two columns), then the data table itself,

Re: [R] data import problem

2006-03-08 Thread Arne.Muller
, Arne -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Philipp Pagel Sent: Wednesday, March 08, 2006 12:44 To: r-help@stat.math.ethz.ch Subject: Re: [R] data import problem On Wed, Mar 08, 2006 at 12:32:28PM +0100, [EMAIL PROTECTED] wrote: I'm trying

Re: [R] data import problem

2006-03-08 Thread Carlos Ortega
a thousands of small files ... . kind regards, Arne -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Philipp Pagel Sent: Wednesday, March 08, 2006 12:44 To: r-help@stat.math.ethz.ch Subject: Re: [R] data import problem On Wed, Mar 08

Re: [R] data import problem

2006-03-08 Thread Sean Davis
On 3/8/06 6:43 AM, Philipp Pagel [EMAIL PROTECTED] wrote: On Wed, Mar 08, 2006 at 12:32:28PM +0100, [EMAIL PROTECTED] wrote: I'm trying to read a text data file that contains several records separated by a blank line. Each record starts with a row that contains it's ID and the number of

Re: [R] data import problem

2006-03-08 Thread Philipp Pagel
On Wed, Mar 08, 2006 at 12:49:29PM +0100, [EMAIL PROTECTED] wrote: Well, the data is generated by a perl script, and I could just configure the perl script so that there is one file per data table, but I though I'd probably must more efficent to have all records in a single file rather than

Re: [R] data import problem

2006-03-08 Thread Gabor Grothendieck
Check out: http://finzi.psych.upenn.edu/R/Rhelp02a/archive/52957.html for a similar problem. On 3/8/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Dear All, I'm trying to read a text data file that contains several records separated by a blank line. Each record starts with a row that

Re: [R] data import problem

2006-03-08 Thread Thomas Lumley
On Wed, 8 Mar 2006, [EMAIL PROTECTED] wrote: I thought I coudl simply use something line this: con - file(test2.txt); do { e - read.table(con, nlines = 1); if ( length(e) == 2 ) { d - read.table(con, nrows = e[1,2]); #process data frame d } } while (length(e) == 2);