[R-sig-ME] Another case of -1.0 correlation of random effects
Kevin E. Thorpe
kevin.thorpe at utoronto.ca
Thu Apr 15 22:43:57 CEST 2010
Kevin E. Thorpe wrote:
> Ben Bolker wrote:
>> Ken Knoblauch wrote:
>>> Kevin E. Thorpe <kevin.thorpe at ...> writes:
>>>
>>>> My data come from a crossover trial and are balanced.
>>>>
>>>> > str(gluc)
>>>> 'data.frame': 96 obs. of 4 variables:
>>>> $ Subject : int 1 2 3 5 6 7 10 11 12 13 ...
>>>> $ Treatment: Factor w/ 2 levels "Barley","Oat": 1 1 1 1 1 1 1 1 1
>>>> 1 ...
>>>> $ Dose : int 8 8 8 8 8 8 8 8 8 8 ...
>>>> $ iAUC : num 110 256 129 207 244 ...
>>>>
>>>> clip>
>>> Shouldn't you make Subject into a factor?
>>>
>>> Ken
>>>
>>
>> It would make the plot a little bit prettier but I don't think it
>> matters in this case because variable that appears as a grouping
>> variable (i.e. on the right of the | ) is automatically treated as a
>> factor? I think?
>>
>> Since it is really a crossover trial, it would seem reasonable in
>> principle to have the (Treatment|Subject) random effect in there as
>> well. I'm not sure what to do about the -1 correlation: it seems the
>> choices (not necessarily in order) are (1) throw up your hands and say
>> there's not enough data to estimate independently; (2) try WinBUGS,
>> possibly with slightly informative priors; (3) try using lme4a to create
>> profiles of the parameters and see if you can figure out what's
>> happening.
>
> Let's see. I wish (1) was an option. (2) would be promising if my
> knowledge of BUGS and Bayesian methods filled more than a thimble.
> Thanks to Jarrod for his suggestion in response to this. I'll take a
> look at that too. Option (3) is probably worth a go too.
>
> Aside from the fact that the Dose variable are the actual doses and not
> categories, and we all know not to categorize continuous variables, what
> are your thoughts on treating Dose as a factor (since it seems to behave)?
>
> Thanks all for taking the time to provide your suggestions.
>
> Kevin
>
Okay, I now have lme4a installed and I get an error message when I do
(note: this is the same model from my OP):
> gluc.lmer1a <-
lmer(iAUC~Dose+(Dose|Subject),data=gluc,subset=Treatment=="Oat",REML=FALSE)
> gluc.lmer1a
Linear mixed model fit by maximum likelihood ['lmer']
Formula: iAUC ~ Dose + (Dose | Subject)
Data: gluc
Subset: Treatment == "Oat"
AIC BIC logLik deviance
575.1 586.3 -281.6 563.1
Random effects:
Groups Name Variance Std.Dev. Corr
Subject (Intercept) 7492.19 86.557
Dose 14.68 3.831 -1.000
Residual 4727.27 68.755
Number of obs: 48, groups: Subject, 12
Fixed effects:
Estimate Std. Error t value
(Intercept) 309.352 29.338 10.544
Dose -14.424 3.533 -4.083
Correlation of Fixed Effects:
(Intr)
Dose -0.647
> pr1 <- profile(gluc.lmer1a at env) ## using @env base on other threads
Error in x[ndat + (1L:deg) - deg] :
only 0's may be mixed with negative subscripts
Is this because I'm trying to profile a model that profile() cannot
handle yet, or does it indicate there really are serious problems with
my model?
I'm at a loss as to how determine what is really going on with these data.
Kevin
--
Kevin E. Thorpe
Biostatistician/Trialist, Knowledge Translation Program
Assistant Professor, Dalla Lana School of Public Health
University of Toronto
email: kevin.thorpe at utoronto.ca Tel: 416.864.5776 Fax: 416.864.3016
More information about the R-sig-mixed-models
mailing list