[R-sig-ME] lmer versus glm results
chingren at umn.edu
Thu May 26 06:53:24 CEST 2011
Thanks very much for your response. Here are the commands I ran.
glm(leaving ~ quarter + project_scope + project_size + tenure +
pastwork, family=binomial("logit"), data=all)
lmer(leaving ~ quarter + project_scope + project_size + tenure +
pastwork + ( 1 + quarter | project_id) + (1 + quarter | user_id),
On Wed, May 25, 2011 at 3:38 PM, Thomas Levine <tkl22 at cornell.edu> wrote:
> Could you post the commands you ran?
> On Wed, May 25, 2011 at 12:25 PM, Yuqing Ren <chingren at umn.edu> wrote:
>> Dear All,
>> I have a quick questions about comparing results from lmer and from
>> glm. We are running analysis to predict a person's likelihood of
>> leaving a project with some people affiliated with multiple projects
>> (binary outcome and crossed random effects).
>> The data consist of three levels: projects, members (crossed with
>> projects with 70% members with one project and 30% with multiple
>> projects), and time series nested within individuals. I ran the
>> analysis with first glm (family=binomial) and then lmer
>> (family-binomial and + (1 | projectid) + (1 | memberid) to account for
>> the random effects). The two analyses have the same covariates:
>> project size and scope and some individual member attributes such as
>> tenure and past performance.
>> Theoretically, I expect the coefficients to be similar between the two
>> results with some differences in the significance test or confidence
>> intervals. However, I found three coefficients flipped signs between
>> the two, which is very puzzling. I ran another set of analysis with a
>> continuous dependent variable (quantity of work completed) and found
>> similar coefficients between the two (results from lm and lmer).
>> So my question is: should we expect the results from glm and lmer to
>> be similar? If we should see different results, is it because of the
>> distribution being binomial rather than normal or other reasons? Which
>> set of results is more reliable and should be included in our paper?
>> Thanks very much.
>> Ching Ren
>> R-sig-mixed-models at r-project.org mailing list
Yuqing (Ching) Ren
Assistant Professor at Carlson School of Management
University of Minnesota, CSOM 3-370
321 19th Avenue S., Minneapolis, MN 55455
(tel) 612-625-5242 (fax) 612-626-1316
More information about the R-sig-mixed-models