[R] format of summary.lm for 2-way ANOVA

Patrick Drechsler patrick at pdrechsler.de
Sat Mar 3 12:22:03 CET 2007


Chuck Cleland <ccleland at optonline.net> writes:

> Patrick Drechsler wrote:

[...]
>> To see the interactions in detail I call summary.lm:
>> 
>> ,----
>> | > summary.lm(model1)
[...]
>> | xVel.L           1.079042   0.061859  17.444  < 2e-16 ***
>> | xVel.Q           0.339802   0.061439   5.531 6.03e-08 ***
>> | xVel.C           0.015422   0.060751   0.254   0.7997    
>> | xVel^4          -0.044399   0.060430  -0.735   0.4630    
[...]

>> I am wondering what the logic is behind the formatting of
>> rownames. What do the strings "L", "Q", "C" and "^4" mean?
>
>   The default contrast for ordered factors is contr.poly(), and "L",
> "Q", "C" and "^4" refer to linear, quadratic, cubic, and quartic,
> respectively.

Thank you very much this explanation! Could you point me in the right
direction where this is documented? I have looked at ?summary,
?summary.lm and ?contr.poly etc.

>   You might look at some plots if you have not already.  For example:
>
> with(mydataset, interaction.plot(xForce, xVel, log(y)))
>
> library(lattice)
> bwplot(log(y) ~ xForce | xVel, data = mydataset)

Nice, thanks also for this pointer.

Cheers

Patrick
-- 
By working faithfully eight hours a day,
you may eventually get to be boss and work twelve.
		-- Robert Frost



More information about the R-help mailing list