Re: [R] selecting rows for inclusion in lm

From: Vladimir Eremeev <wl_at_eimb.ru>
Date: Thu 18 Jan 2007 - 08:51:54 GMT

> Why not use the subset option? Something like:
>
> lm(diff ~ Age + Race, data=data, subset=data$Meno=="PRE")

> should do the trick, and be much easier to read!

"data$" could be omitted, simply
lm(diff ~ Age + Race, data=data, subset=Meno=="PRE")



R-help@stat.math.ethz.ch 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 Thu Jan 18 19:56:47 2007

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 Thu 18 Jan 2007 - 09:30:25 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.