[R-sig-ME] A Question about specifying error variance/covariance structure in lmer

Douglas Bates bates at stat.wisc.edu
Thu May 12 19:10:27 CEST 2011


On Tue, May 10, 2011 at 9:47 AM, Chester Kam <chester_kam at yahoo.com> wrote:
> Hi all,
>
> I am conducting an analysis in which I need to specify the error
> variance/covariance structure in a Linear Mixed Model analysis. Specifically, I
> had 60 participants, each of them rated their liking of a close and non-close
> other at the end of the day, for consecutive 6 days. The datafile has the
> following structure:
>
>
> Participant_id Day
> (e.g., 1 = first day of rating; 2 = second day of rating) Target
> (1 = close other;
> 2 = non-close other) Liking of Target
> (from 1 to 9)
> 1 1 1 8
> 1 1 2 9
> 1 2 1 7
> 1 2 2 6
> 1 3 1 5
> 1 3 2 7
> 1 4 1 8
> 1 4 2 9
> 1 5 1 7
> 1 5 2 6
> 1 6 1 6
> 1 6 2 8
> 2 1 1 9
> 2 1 2 9
> 2 2 1 7
> 2 2 2 6
> 2 3 1 5
> 2 3 2 6
> 2 4 1 4
> 2 4 2 5
> 2 5 1 8
> 2 5 2 7
> 2 6 1 6
> 2 6 2 4
> 3 1 1 5
> 3 1 2 6
> 3 2 1 6
> 3 2 2 7
> 3 3 1 8
> 3 3 2 9
> 3 4 1 8
> 3 4 2 7
> 3 5 1 6
> 3 5 2 5
> 3 6 1 4
> 3 6 2 8
> My major interest is to examine whether there is a main effect of target on
> liking, and whether there is an interaction effect between target and other
> personality variables (personality variables not shown here) on liking.
>
> The MLM equation is as follow:
>
> Liking = Intercept + Beta1*Target + Beta2*Personality + Beta3*Target*Personality
> + Participants' Random Effect + Error,
> and the error covariance structure of day is specified as AR (Heterogeneous).
>
> However, I keep obtaining an error message that complains about having two
> ratings on each day, and thus it cannot model the error covariance structure
> properly. In another trial analysis, I only have one rating on each day and the
> program no longer complains.

You will need to provide us with more information.  Your subject line
mentions the lmer function but you don't show us any calls to lmer and
the results of those calls.  You provide an "MLM equation" which I
presume has something to do with MultiLevel Modeling but that is not
how a model is specified in lmer.

> Should I specify the error covariance structure in my data? Alternatively,
> should I simply specify the time (i.e., day) as another random effect? Thank you
> very much for your help. It is much appreciated!
>
> Chester Kam
> Doctoral Student, Psychology
> University of Western Ontario
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-mixed-models at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>




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