Re: [R] how to skip certain rows when reading data

From: Gabor Grothendieck <>
Date: Fri 28 Jul 2006 - 04:23:39 EST

Just read them in and throw them away:

   read.table("myfile.dat", ...whatever...)[-c(10, 12), ]

On 7/27/06, <> wrote:
> Dear all,
> I am reading the data using "read.table". However, there are a few rows I
> want to skip. How can I do that in an easy way? Suppose I know the row
> number that I want to skip. Thanks so much! mailing list PLEASE do read the posting guide and provide commented, minimal, self-contained, reproducible code. Received on Fri Jul 28 04:29:20 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Fri 28 Jul 2006 - 06:17:23 EST.

Mailing list information is available at Please read the posting guide before posting to the list.