[R] package for repeated measures ANOVA with various link functions REDUX
John Sorkin
jsorkin at grecc.umaryland.edu
Wed Mar 5 04:48:07 CET 2008
Prof. Bates was correct to point out the lack of specifics in my original posting. I am looking for a package that will allow we to choose among link functions and account for repeated measures in a repeated measures ANOVA.
My question is what package should I use to facilitate estimating rates of illegal drug use at three centers, and the effect two interventions have on usage. At each center data describing the rate of drug use was obtained once a month. For the first six-months, there was no intervention at any of the three centers. For months seven through 13 intervention one was applied at each of the three centers. For months 14 through 24 intervention two was applied at each center. The question I am trying to answer is did intervention one or two change drug usage at any of the three centers. I am treating center as a repeated measure, i.e. the rate of drug use at month one will be correlated with the rate of drug use at center one at months two, three, etc.
I have accounted for repeated measures several ways in the past.
(1) I have used SAS proc MIXED with a REPEATED statement. The REPEATED statement allows for the specification of the within-subject correlation of repeated measures by specifying the structure of the within-subject variance-covariance matrix of the repeated measures. The matrix is block diagonal with one block for each subject.
(2) I have used SAS proc GENMOD which uses GEE to adjust the parameter estimates and their standard errors for the fact that a repeated measurements of a parameter are obtained from a given subjects.
Is there any package in R that will allow me to perform a repeated measures ANOVA with a selection of link functions that will allow me to account for repeated measures by either specifying the correlation structure of the repeated measures from a subject a la SAS proc mixed or by adjusting the parameter estimates using GEE a la proc GENMOD? Perhaps R has a package that accounts for repeated measures in some other manner.
Thank you,
John Sorkin
John Sorkin M.D., Ph.D.
Chief, Biostatistics and Informatics
University of Maryland School of Medicine Division of Gerontology
Baltimore VA Medical Center
10 North Greene Street
GRECC (BT/18/GR)
Baltimore, MD 21201-1524
(Phone) 410-605-7119
(Fax) 410-605-7913 (Please call phone number above prior to faxing)
>>> "Douglas Bates" <bates at stat.wisc.edu> 3/4/2008 5:13 PM >>>
On Tue, Mar 4, 2008 at 10:52 AM, John Sorkin
<jsorkin at grecc.umaryland.edu> wrote:
> R 2.6.0
> Windows XP
> At the risk of raising the ire of the R gods . . .
> I am looking for a package that will allow me to perform a poisson, quasipoisson, or negative binomial regression with adjustment for repeated measures. I have looked at glm, it does not appear to allow repeated measures. Although I can't get any help for lme or lme4 I remember that those packages perform repeated measures using random effects, not repeated measures ANOVA which is what I am looking for. (By the why, how can I get help for lme4? I have tried ?lme4, help.search("lme4") etc. to no avail.)
> A suggestion for a package that will allow for repeated measures ANOVA in the context of various link functions would be appreciated.
I think you would need to be more specific about the model than just
saying "repeated measures ANOVA". To me, "repeated measures"
describes a structure in the data. There are many ways that one could
model the effects of the repeated measures; some might make sense in
the context of your data and some might not. Without further details
about how you want to model the effect of the repeated measurements it
would be difficult to say if you could use the lmer function in the
lme4 package to do so.
The purpose of the S language and the R implementation of that
language is to facilitate exploration of data, including the fitting
of models that may be appropriate - always keeping in mind George
Box's famous statement that, "All models are wrong, but some models
are useful". The "one size fits all" approach to data analysis - also
known as "give me a quart and a half of statistics and just make sure
that there is a p-value less than 5% somewhere in there" - doesn't fit
well into the R system.
Confidentiality Statement:
This email message, including any attachments, is for th...{{dropped:6}}
More information about the R-help
mailing list