[R-sig-ME] R-sig-mixed-models Digest, Vol 157, Issue 14

C. AMAL D. GLELE @|te@@ed@c2 @end|ng |rom gm@||@com
Tue Jan 21 10:05:31 CET 2020


Dear Ben,
thank you so much.
Best,

Le lun. 20 janv. 2020 à 11:19, <r-sig-mixed-models-request using r-project.org> a
écrit :

> Send R-sig-mixed-models mailing list submissions to
>         r-sig-mixed-models using r-project.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
> or, via email, send a message with subject or body 'help' to
>         r-sig-mixed-models-request using r-project.org
>
> You can reach the person managing the list at
>         r-sig-mixed-models-owner using r-project.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of R-sig-mixed-models digest..."
>
>
> Today's Topics:
>
>    1. Problem_Downdated VtV is not positive definite (C. AMAL D. GLELE)
>    2. Re: Problem_Downdated VtV is not positive definite (Ben Bolker)
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Sun, 19 Jan 2020 13:29:54 +0000
> From: "C. AMAL D. GLELE" <altessedac2 using gmail.com>
> To: R SIG Mixed Models <r-sig-mixed-models using r-project.org>
> Subject: [R-sig-ME] Problem_Downdated VtV is not positive definite
> Message-ID:
>         <
> CANrzCv0JTGCDDrJ0eRuVQGOKpdtMLvAy3XPBWNotJfkD4nECOw using mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Hello, everyone.
> In the models below, mydata has 32 rows
> village and Year are grouping factor variables with respectively 8 and 4
> levels.
> 1)
> model1.1 fits well
> model1.1<-glmer(cbind(F,L)~village+Year+(1|Year)+(1|village),
> family="binomial",data=mydata)
> But, when I replace village+Year by village*Year, I get the warning and
> error message below
> model1.2<-glmer(cbind(F,L)~village*Year+(1|Year)+(1|village),
> family="binomial",data=mydata)
> Warning:
> fixed-effect model matrix is rank deficient so dropping 2 columns /
> coefficients
> Error message:
> Error in (function (fr, X, reTrms, family, nAGQ = 1L, verbose = 0L, maxit =
> 100L,  :
>   Downdated VtV is not positive definite
> I noticed a similar behavior when trying with glmmadmb:
> model2.1 fits well
>
> model2.1<-glmmadmb(cbind(F,L)~village+Year+(1|Year)+(1|village),family="binomial",data=na.omit
>
> (mydata))
> But, with village*Year, Iget the error message below:
>
> model2.2<-glmmadmb(cbind(F,L)~village*Year+(1|Year)+(1|village),family="binomial",data=na.omit
>
> (mydata))
> Error:
> Error in glmmadmb(cbind(F, L) ~ village * Year + (1 | Year) + (1 |
> village),  :
>   rank of X = 30 < ncol(X) = 32
> ##
> in advance, thanks for helping solve these issues(I'm very interested in
> interaction terms).
> Kinds regards,
>
>         [[alternative HTML version deleted]]
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Sun, 19 Jan 2020 19:46:02 -0500
> From: Ben Bolker <bbolker using gmail.com>
> To: r-sig-mixed-models using r-project.org
> Subject: Re: [R-sig-ME] Problem_Downdated VtV is not positive definite
> Message-ID: <b102d218-f1b4-1628-7e73-a34664dc55b4 using gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
>
>
> On 2020-01-19 8:29 a.m., C. AMAL D. GLELE wrote:
> > Hello, everyone.
> > In the models below, mydata has 32 rows
> > village and Year are grouping factor variables with respectively 8 and 4
> > levels.
> > 1)
> > model1.1 fits well
> > model1.1<-glmer(cbind(F,L)~village+Year+(1|Year)+(1|village),
> > family="binomial",data=mydata)
> > But, when I replace village+Year by village*Year, I get the warning and
> > error message below
> > model1.2<-glmer(cbind(F,L)~village*Year+(1|Year)+(1|village),
> > family="binomial",data=mydata)
> > Warning:
> > fixed-effect model matrix is rank deficient so dropping 2 columns /
> > coefficients
> > Error message:
> > Error in (function (fr, X, reTrms, family, nAGQ = 1L, verbose = 0L,
> maxit =
> > 100L,  :
> >   Downdated VtV is not positive definite
>
>    When you include a fixed effect of village*Year, it expands to (1 +
> village + Year + village:Year).
>
>   Assuming Year is numeric, the combination of a fixed effect of Year
> (treated as the overall slope of a linear relationship) and a random
> intercept of Year (Year treated as a categorical grouping variable) is OK.
>
>   But ... you also have village as categorical fixed effect *and* a
> random intercept, which is redundant.
>
>    You could use  ~ Year + village:Year  + (1|Year) + (1|village) *or*
>                   ~ Year + (1+Year|village)
>
>
>
> > I noticed a similar behavior when trying with glmmadmb:
> > model2.1 fits well
> >
> model2.1<-glmmadmb(cbind(F,L)~village+Year+(1|Year)+(1|village),family="binomial",data=na.omit
> >
> > (mydata))
> > But, with village*Year, Iget the error message below:
> >
> model2.2<-glmmadmb(cbind(F,L)~village*Year+(1|Year)+(1|village),family="binomial",data=na.omit
> >
> > (mydata))
> > Error:
> > Error in glmmadmb(cbind(F, L) ~ village * Year + (1 | Year) + (1 |
> > village),  :
> >   rank of X = 30 < ncol(X) = 32
> > ##
> > in advance, thanks for helping solve these issues(I'm very interested in
> > interaction terms).
> > Kinds regards,
> >
> >       [[alternative HTML version deleted]]
> >
> > _______________________________________________
> > R-sig-mixed-models using r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
> >
>
>
>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> R-sig-mixed-models mailing list
> R-sig-mixed-models using r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-mixed-models
>
>
> ------------------------------
>
> End of R-sig-mixed-models Digest, Vol 157, Issue 14
> ***************************************************
>

	[[alternative HTML version deleted]]



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