Skip to content

Repeated Measures, groupedData and lme

2 messages · emma pilgrim (IGER-NW), Douglas Bates

13 days later
#
emma pilgrim (IGER-NW) wrote:
Are you sure you want treatment to be the grouping factor?
This is an unfortunate side-effect of creating a groupedData object - to 
create plots with panels in a natural order the grouping factor is 
changed to an ordered factor.  In your case the treatment factor will 
become an ordered factor and the default contrasts for an ordered factor 
are the polynomial contrasts.

There are two ways to get around this - don't create a groupedData 
object or change the default contrasts using

options(contrasts = c(unordered = "contr.treatment", ordered = 
"contr.treatment")
Yes.
Probably that is the best course.