[R] grouping data

Dieter Menne dieter.menne at menne-biomed.de
Wed Jul 20 09:03:54 CEST 2011

adolfpf wrote:
> How do I "group" my data in "dolf" the same way the data "Orthodont" are
> grouped.
>> show(dolf)
>    distance   age Subjectt Sex
> 1    6.83679 22.01       F1   F
> 2    6.63245 23.04       F1   F
> 3   11.58730 39.26       M2   M

I know that many sample in that excellent book use grouped data, but the
concept of "grouped data" is more confusing than helpful. I only got started
using nlme/lme when I realized that everything could be done without grouped
data. Too bad, many examples in Pinheiro/Bates rely on the concept (but no
longer do in the cooooooooommmming lme4).

So I suggest that you try to solve the problem with vanilla data frames
instead of grouped ones. In most cases, it only means that you have to put
the formula into the lme(..) call instead of relying on some hidden


View this message in context: http://r.789695.n4.nabble.com/grouping-data-tp3679803p3680115.html
Sent from the R help mailing list archive at Nabble.com.

More information about the R-help mailing list