Re: [R] Multiple comparisons when interacction

From: Jorge Lampurlanes Castel <>
Date: Fri 16 Feb 2007 - 10:37:40 GMT


Data comes from a multiyear field experiment in which 4 levels of a treatment (2, 3, 4, 6) are compared to see the effect on yield. It is a randomized complete block design.

The SAS code follows:

options ls=95;
data uno;

        infile 'data.csv' delimiter=';' firstobs=2;
        input year plot block treat yield;

proc mixed data=uno;

     class treat year block;
     model yield=block year treat treat*year;
     lsmeans year treat  /pdiff;
     lsmeans treat*year /slice=year pdiff;
     ods output diffs=dos;


data tres;

      set dos;
      if year=_year;
proc print data=tres;
      var year _year treat _treat estimate stderr df tvalue probt;

Data are attached as a file: data.csv.

In fact, I do not know if this is the best approach to analyze the data:

In multcomp package:

Thanks a lot for your interest.

Jorge Lampurlanés

>> Is it possible to do this analysis in R?
> Yes, it is possible. The syntax isn't in place yet.
> If you send me the complete SAS code and data for an example using slice,
> I will duplicate it for you in the multcomp package in R. I will send
> that
> to the R-help list and to Torsten and it will bring us one step closer
> to the syntax.
> The example I showed before was designed to get the same answer as S-Plus
> multicomp using the adjust= argument.
> Rich
> mailing list PLEASE do read the posting guide and provide commented, minimal, self-contained, reproducible code. Received on Fri Feb 16 21:45:26 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 Fri 16 Feb 2007 - 11:30:38 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.