From: Dawn Ashcourt <dawn.ashcourt_at_gmail.com>

Date: Tue 16 Jan 2007 - 09:30:22 GMT

.... et cetera.

There are seven groups in all, each with a different number of observations. The idea is to compare a model in which all the data points can be modeled with a single mean (i.e., if all the group means are equal), or if the data suggests that each of the groups has a different mean. In other words, I want to do a Likelihood ratio test on whether or not the group means are significantly different from each other: the full model would be glm(data ~ as.factor(group)-1, family = gaussian), to be compared against a restricted model that only includes an intercept. However, I also need to allow for the fact that each group has a different variance. And this I have no idea how to do. I would really appreciate some help in this matter. Thank you in advance,

Dawn.

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue Jan 16 21:03:15 2007

Date: Tue 16 Jan 2007 - 09:30:22 GMT

Hello - I am fairly new to R, (i.e., ability to create functions/write
programs insignificant) and was wondering if there might be a convenient way
to model the following: I want to fit a gaussian glm to grouped data, while
allowing for unequal variances in each of the groups.
More specifically, my data set looks something like this:

data group

1 76 1 2 82 1 3 83 1 4 54 1 5 35 1 6 46 1 7 87 1 8 68 1 9 87 2 10 95 2 11 98 2 12 100 2 13 109 2 14 109 2 15 100 2 16 81 2 17 75 2 18 68 2 19 67 2 20 105 3

.... et cetera.

There are seven groups in all, each with a different number of observations. The idea is to compare a model in which all the data points can be modeled with a single mean (i.e., if all the group means are equal), or if the data suggests that each of the groups has a different mean. In other words, I want to do a Likelihood ratio test on whether or not the group means are significantly different from each other: the full model would be glm(data ~ as.factor(group)-1, family = gaussian), to be compared against a restricted model that only includes an intercept. However, I also need to allow for the fact that each group has a different variance. And this I have no idea how to do. I would really appreciate some help in this matter. Thank you in advance,

Dawn.

[[alternative HTML version deleted]]

R-help@stat.math.ethz.ch mailing list

https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue Jan 16 21:03:15 2007

Archive maintained by Robert King, hosted by
the discipline of
statistics at the
University of Newcastle,
Australia.

Archive generated by hypermail 2.1.8, at Tue 16 Jan 2007 - 12:30:27 GMT.

*
Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help.
Please read the posting
guide before posting to the list.
*