[R] lines those not started with "rs"

Robert Sherry rsherry8 at comcast.net
Mon Jan 30 15:36:45 CET 2017


I am assuming that your data is in a text file. R is a good tool but not 
the tool I would use for this job. The tool I would
use is grep. The following command should get you want you want:
          grep -v "^rs" <data file name>


On 1/30/2017 9:23 AM, greg holly wrote:
> Hi all;
> I have a file which has about 3.000.000 lines. Most of the lines at first
> column start with "rs", for example, rs10000056, rs10000076 and so on. I
> would like to get the lines which do not start with "rs" . Your helps
> highly appreciated.
> Regards,
> Greg
> 	[[alternative HTML version deleted]]
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> 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.

More information about the R-help mailing list