Skip to content
Prev 4366 / 20628 Next

longitudinal with 2 time points

Hi Marc, thanks for your comments. Yes, I am debating between the 2 models as 
well. 


The first model doesnot have a "time" variable, and there is only 1 level of 
nesting: arm within subject. I think the syntax for nesting is   (1|subject / 
arm) instead of (1|arm/subject).

The 2nd model certainly have a different layout of data with a "time" variable. 
It has 2-level nesting: arm within subject within time, so the syntax should 
(1|time/subject/arm)?

Now I have a little confusion on how to define the nesting here. Can I define it 
as arm within time within subject instead? so the syntax would be 
(1|arm/time/subject)? The reason I am thinking of this way is: each subject was 
measured at 2 time points (0 & 4), at each time point, measured twice at 2 arms 
(left & right).

What is the simplest way to define nesting structure? any principles that we 
should follow? Sometimes I feel I can use different nesting structures as they 
all sound reasonable to me.

Really wish someone can chime in and share their thoughts.

John




----- Original Message ----
From: Marc Schwartz <marc_schwartz at me.com>
To: array chip <arrayprofile at yahoo.com>
Cc: r-sig-mixed-models at r-project.org
Sent: Tue, August 24, 2010 11:55:36 AM
Subject: Re: [R-sig-ME] longitudinal with 2 time points

Hi John,

Since we have crossed the threshold into mixed models, I am going to provide 
some comments, but (notably because I have not used lmer, although I attended 
Doug's class a few years ago at useR), will defer to and solicit comments from 
the lmer experts on the list.

First, I am not sure, unless we restate the model where Glucose is the response 
variable and Time is a covariate, that using Time in the random effects term 
make sense. But I could be wrong.

If we stay with and extend the ANCOVA style approach, then I might envision 
something like:
  
  lmer(wk4.glucose ~ baseline.glucose + treatment + gender + age + 
       (1 | arm / subject))

where the random effect term expresses the nesting of arm within subject. I am 
also presuming that you are not interested in arm as a main effect. So we are 
still concerned with the other main effects as before, but now consider the 
variation in the multiple measurements of glucose from each arm within each 
subject.

If you restate the model as I noted above, then perhaps:

  lmer(glucose ~ time + treatment + gender + age + 
       (1 | arm / subject / time))

might make sense. From a review of the archives, it would seem that a 
multi-level nesting is permitted in lmer formulae random effects terms, so this 
would reflect the nesting of arm, within subject, within time. The 
interpretation of this model is of course, going to be different than the ANCOVA 
based approach above.

Hopefully, this might at least provide a starting point for further discussion 
and others with greater expertise will chime in.

Regards,

Marc

P.S. Note that I trimmed some of the thread below, to conserve space...
On Aug 24, 2010, at 3:02 AM, array chip wrote:

            
baseline.