Hi DRUG,
I have a mixed model conundrum that I’m wondering if someone can help me understand. For my study I grew plants under 9 different fertilizer conditions and measured yield across many farmers’ plots in two different seasons. Because some farmers left the study and others joined, I have an unbalanced design with some sites only participating in Year 1 (7), others only participating in Year 2 (14), and still others who participated both years (24). This leads to the majority of sites violating the assumption of independence and requiring a repeated measure.
Beyond having some sites that participated twice, I also have a mixed design: my farm sites are random (to extend the conclusions to the general region), but my treatments are fixed (my treatments are discrete conditions and generalizing outside of them would not make sense). Year is also fixed because I only have two years and do not want to expend the conclusions to other years.
My question is: is this model using R’s nlme package appropriate to analyze a mixed model with repeated measures? How does the lme command take into account the unbalanced design and repeated measure? If it does! This is based off of examples I found online, but I haven’t found the online resources super helpful. Does anyone out there have a superior knowledge of nlme than me who could tell me if this model is appropriate?
mod <- lme(yield ~ treatment + season, random= ~1|site, data=df)
Thanks in advance!
Lauren
--
Check out our R resources at http://www.noamross.net/davis-r-users-group.html
---
You received this message because you are subscribed to the Google Groups "Davis R Users' Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to davis-rug+...@googlegroups.com.
Visit this group at http://groups.google.com/group/davis-rug.
For more options, visit https://groups.google.com/d/optout.
--
Thanks so much Bonnie and Jaime! Yes, Bonnie, we talked about this last year maybe – I’m dealing with comments now and one comment is about the repeated measures part of my design. I remember thinking about that as I set up this model, but now I don’t remember how nmle deals with repeated measures. Bonnie, would you mind explaining what you meant when you said “Season would still be the repeats in your repeated measures design even if it is not modeled explicitly as a variable?” Like Jaime said, I only have two repeated measurements per site. I don't know if that means running the model like I did [ mod <- lme(yield ~ treatment + season, random= ~1|site, data=df) ] means the estimated slopes and intercepts (for seasons only?) are highly correlated and shouldn't be trusted.
I went with seasons in the model instead of using the rainfall data I had since rainfall actually does NOT have a significant effect, but season is significant. So there are other things that happened that season that made a difference and I discuss what those could be.
Thanks again!
Thanks so much Bonnie and Jaime! Yes, Bonnie, we talked about this last year maybe – I’m dealing with comments now and one comment is about the repeated measures part of my design. I remember thinking about that as I set up this model, but now I don’t remember how nmle deals with repeated measures. Bonnie, would you mind explaining what you meant when you said “Season would still be the repeats in your repeated measures design even if it is not modeled explicitly as a variable?” Like Jaime said, I only have two repeated measurements per site. I don't know if that means running the model like I did [ mod <- lme(yield ~ treatment + season, random= ~1|site, data=df) ] means the estimated slopes and intercepts (for seasons only?) are highly correlated and shouldn't be trusted.
I went with seasons in the model instead of using the rainfall data I had since rainfall actually does NOT have a significant effect, but season is significant. So there are other things that happened that season that made a difference and I discuss what those could be.
Thanks again!
--