Guillaume Adeux
2018-10-23 10:06:07 UTC
Hi everyone,
I wanted to allow for different variances across treatment levels so I
headed towards nlme:lme in order to use varIdent().
However, I also have crossed random effects (year and plot) which needs a
little hack in nlme:lme to specify.
Hence the final model is:
dat$Grp=1 ### fake grouping in order to create grouped data object
gr=groupedData(response~time|Grp,data=dat) ### grouped data object
mod4 <- lme(response~ block+treatment*time, random =
pdBlocked(list(pdIdent(~ year - 1),pdIdent(~ plot -
1))),weights=varIdent(form=~1|treatment), data=gr,method="ML")
The question now is: is it possible to supply such a model to
monet::test_terms() ?
I cannot find such examples in
https://rdrr.io/github/singmann/monet/src/examples/examples.test_terms.R
Thank you all once again for you help.
Sincerely,
Guillaume ADEUX
Nb: if I understood correctly from previous messages, this type of model
(crossed random effects, specific variance structure) could also be fitted
with glmmTMB
[[alternative HTML version deleted]]
I wanted to allow for different variances across treatment levels so I
headed towards nlme:lme in order to use varIdent().
However, I also have crossed random effects (year and plot) which needs a
little hack in nlme:lme to specify.
Hence the final model is:
dat$Grp=1 ### fake grouping in order to create grouped data object
gr=groupedData(response~time|Grp,data=dat) ### grouped data object
mod4 <- lme(response~ block+treatment*time, random =
pdBlocked(list(pdIdent(~ year - 1),pdIdent(~ plot -
1))),weights=varIdent(form=~1|treatment), data=gr,method="ML")
The question now is: is it possible to supply such a model to
monet::test_terms() ?
I cannot find such examples in
https://rdrr.io/github/singmann/monet/src/examples/examples.test_terms.R
Thank you all once again for you help.
Sincerely,
Guillaume ADEUX
Nb: if I understood correctly from previous messages, this type of model
(crossed random effects, specific variance structure) could also be fitted
with glmmTMB
[[alternative HTML version deleted]]