[R] how to code y~x/(x+a) in lm() function
Ben Bolker
bbolker at gmail.com
Wed Aug 21 17:49:34 CEST 2013
Rolf Turner <rolf.turner <at> xtra.co.nz> writes:
>
> On 21/08/13 11:23, Ye Lin wrote:
> > T
> > hanks for your insights Rolf! The model I want to fit is y=x/a+x with
> > no intercept, so I transformed it to 1/y=1+a/x as they are the same.
>
> For crying out loud, they are ***NOT*** the same. The equations y =
> x/(a+x) and
> 1/y = 1 + a/x are indeed algebraically identical, but if an "error" or
> "noise" term is added
> to each then then the nature of the error term is vastly different. It
> is the error or
> noise term that is of central concern in a statistical context.
>
> cheers,
>
> Rolf
For what it's worth this model can also be fitted (without messing
up the error structure) via
glm(1/y~x,family=gaussian(link="inverse"))
Although you may not get the parameters in exactly the form you
want.
More information about the R-help
mailing list