Thanks for the help. Sorry but now comes the second question. What we have now assumes equal within-subject variances. How can I fit separate (pooled) within-subject variances for each group (similar to an unequal variance t-test) and test if this is better than the existing constant within-subject variance.
Many thanks Ross Douglas Bates <[EMAIL PROTECTED]> writes: > Ross Darnell <[EMAIL PROTECTED]> writes: > >> I would like some advice on how if possible, to test the following >> >> I have subjects each measured several times. The subjects are sampled >> from 3 subpopulations (groups). The question is "Is the >> between-subject variance the same for the three groups?" >> >> The "null" model is >> >> lme0 <- lme(y~group,random=~1|subject) >> >> I did think that the model that defined a specific between-subject >> variance for each group was >> >> update(lme0,.~., weights=varIdent(form=~1|group)) >> >> but I am not sure. > > I think you have it right. You should then compare the two fitted > models using the anova generic, which will provide a likelihood ratio > test statistic and a p-value based on a chi-squared reference > distribution. Regard the p-value as an approximation. > > > -- Ross Darnell School of Health and Rehabilitation Sciences University of Queensland, Brisbane QLD 4067 AUSTRALIA Email: <[EMAIL PROTECTED]> Phone +61 7 3365 6087 http://www.uq.edu.au/~uqrdarne/ ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help