> On Wed, 19 Feb 2003, Sharon Kuhlmann-Berenzon wrote: > > > > > Hi R-help, > > > > Is there such a thing as a function in R for fitting a GLM where the > > response is distributed as a Beta distribution? > > > > In my case, the response variable is a percentage ([0,1] and continuous). > > > > The current glm() function in R doesn't include the Beta distribution. > > > > That's because they aren't generalised linear models. > > Two simple possibilities > > - use the quasibinomial variance and an appropriate link such as logit in > glm -- there's an example in McCullagh & Nelder that tries this (though > they decide in the end that it doesn't fit their data very well) > > - Take logits and model with linear regression: a lot of beta > distributions are fairly similar to logit-normal distributions.
A third simple possibility: my gnlr function in my gnlm library, which fits linear and nonlinear regression models with a beta distribution. www.luc.ac.be/~jlindsey/rcode.html Jim > > Or you could write down the loglikelihood and use nlm() or optim() to > maximise it. > > -thomas > > ______________________________________________ > [EMAIL PROTECTED] mailing list > http://www.stat.math.ethz.ch/mailman/listinfo/r-help > ______________________________________________ [EMAIL PROTECTED] mailing list http://www.stat.math.ethz.ch/mailman/listinfo/r-help
