[R-sig-ME] [FORGED] Re: logistic regression on posttest (0, 1) with pretest(0, 1)*Group(Treatment, Ctrl) interaction

Rolf Turner r@turner @end|ng |rom @uck|@nd@@c@nz
Mon Apr 22 01:58:44 CEST 2019

On 22/04/19 6:01 AM, Sorkin, John wrote:

> Souheyla,
> It is both difficult and dangerous to add a comment to a thread that
> one has not followed, and in doing so possibly making an
> inappropriate suggestion. Please forgive what may be an not fully
> informed thought.
> The model you suggest, posttest ~ pretest*Group  (ignoring random
> effects) is unusual. In a model that contains an interaction,  I
> would expect to see, in addition to the interaction, all main effects
> included in the interaction, i.e. posttest ~
> group+pretest+pretest*Group.

As Souheyla has already indicated, in the R (and previously S/Splus) 
formula syntax, interactions are indicated by a *colon* --- a:b.  The 
notation "a*b" is a shorthand for
a + b + a:b.

So pretest*Group is the same as pretest + Group + pretest:Group, whence 
it contains the main effects.

I disagree with the advice that you gave Souheyla in a follow-up email.
The construction pretest*Group is preferable, being compact and tidy. 
Brevity is a virtue.



Honorary Research Fellow
Department of Statistics
University of Auckland
Phone: +64-9-373-7599 ext. 88276

More information about the R-sig-mixed-models mailing list