[R-sig-eco] Log transformed simple linear regression and Poisson regression
Brooks,Mollie E
mbrooks at ufl.edu
Wed Aug 1 20:17:17 CEST 2012
Hi Lin,
If y is count data, then you should probably model it with either the
Poisson or negative binomial distributions because these are for counts.
You can sometimes get away with the normal distribution if the counts
are very large.
There is an article by O'Hara and Kotz in Methods in Ecology and
Evolution titled "Do not log-transform count data". So your first
approach is probably unacceptable.
The similarity is that Poisson regressions typically use a log link
function (the function glm does this by default). A log link means that
the model follows the same exponential form that you've specified in
your first approach (except for the +1). If y does not appear to have an
accelerating relationship with the predictors, you can try an identity
link, but it is more fragile.
cheers,
Mollie
On Thu, 2 Aug 2012 01:42:16 +0800 (CST), lgj200306 wrote:
> Hi, everyone,
> I used two methods to analysis the relationship between y (count
> data) and x.
> 1) log transformed simple linear regression:
>>lm(log(y+1)~x1+x2+x3,data)
> 2) Poisson regression:
>>glm(y~x1+x2+x3,family=poisson())
>
> Some one told that these two ways are very similar, but other one
> told that the Poisson regression does not fit the y but the lambda
> (parameter of the poisson distribution). I am not sure which one is
> right. Can anybody help me?
> Thanks for your attention and best wishes for you!
>
> Lin
> Aug 1st, 2012
> [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
More information about the R-sig-ecology
mailing list