Re: [R] read.table with multiple header lines

From: Gabor Grothendieck <ggrothendieck_at_gmail.com>
Date: Mon, 07 Apr 2008 16:16:32 -0400

If there are no t's in your file other than in the second line then:

read.table("myfile.dat", comment = "t", header = TRUE)

On Mon, Apr 7, 2008 at 1:47 PM, Deborah Kronenberg <Deborah.kronenberg_at_gmx.de> wrote:
> Hello,
>
> I have difficulties in reading in a text file with multiple (=2) header lines. My table looks like this:
>
> id code gr grcode AA AB AC AD
> time 30 40 50 60
> 1 1234 1 c 0 1 0 0
> 2 1346 1 c 0 0 0 1
> 3 1456 1 c 0 0 1 1
> 4 1893 1 c 0 0 1 1
>
> Can someone help me out?
>
> Thanks
>
> Deborah
> --
>
> ______________________________________________
> R-help_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Mon 07 Apr 2008 - 20:19:40 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 07 Apr 2008 - 22:30:27 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive