Re: [R] ANOVA 1 too few degrees of freedom

From: peter dalgaard <pdalgd_at_gmail.com>
Date: Fri, 06 May 2011 08:31:55 +0200

On May 5, 2011, at 23:30 , Rovinpiper wrote:

> Thanks slre,
>
> I seem to be making some progress now.
>
> Using a colon instead of an asterisk in the code really changes things. I
> had been getting residual SS and MS of zero. Which is ridiculous. Now I get
> much more plausible values.
>
> Also, When I used an asterisk instead of a colon It wouldn't give results
> for three way interactions. With colons it will.
>
> You are correct about plot being nested within treatment. There are six
> plots in each of 2 treatments.
>
> So, I guess I will have to perform a separate analysis to quantify the
> effect of treatment.
>

Beware that as you have highly significant effects of plot and its interaction with day, and plot being nested in treatment, you can't test for treatment or treatment:day effect with a systematic effect of plot and plot:treatment in the model (you are only getting p values because of the sequential computation of the anova table - if you put plot before treatment, you'd get zero df). More likely, you want to make the "plot" terms random, as in ~treatment*day + Error(plot/day)

> Thanks again.
>
> Analysis of Variance Table
>
> Response: Combined.Rs
>
> Df Sum Sq Mean Sq F value Pr(>F)
> Combined.Trt 1
> 52.80 52.805 96.2601 < 2.2e-16 ***
> Combined.Plot 10
> 677.69 67.769 123.5380 < 2.2e-16 ***
> as.factor(Combined.Day) 16
> 2817.47 176.092 321.0041 < 2.2e-16 ***
> Combined.Trt:as.factor(Combined.Day) 16 47.82
> 2.989 5.4487 4.048e-10 ***
> Combined.Trt:Combined.Plot:as.factor(Combined.Day)80 455.42 5.693
> 10.3776 < 2.2e-16 ***
> Residuals
> 284 155.79 0.549
> ---
> Signif. codes: 0 *** 0.001 ** 0.01 * 0.05 . 0.1 1
>
>
> --
> View this message in context: http://r.789695.n4.nabble.com/ANOVA-1-too-few-degrees-of-freedom-tp3493349p3499649.html
> Sent from the R help mailing list archive at Nabble.com.
>
> ______________________________________________
> R-help_at_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.

-- 
Peter Dalgaard
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: pd.mes_at_cbs.dk  Priv: PDalgd_at_gmail.com

______________________________________________
R-help_at_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.
Received on Fri 06 May 2011 - 06:36:06 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 10 May 2011 - 21:30:06 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.

list of date sections of archive