On Wed, Apr 17, 2013 at 2:33 PM, Marc Schwartz <marc_schwa...@me.com> wrote:
> If you only want up to say second order interactions:
>
>> summary(lm(mpg ~ (cyl + disp + hp + drat) ^ 2, data = mtcars))
>
This is what I was looking for. Thank you so much.


> This is covered in ?formula
>
Indeed. I tried to parse ?formula at several occasions in the past few
years, but never quite grasped it fully.

Thanks again,
Liviu

______________________________________________
R-help@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.

Reply via email to