[R] p-value for the fitted parameters in linear models

S Ellison S.Ellison at LGCGroup.com
Sun Jun 24 23:41:56 CEST 2012



>> But what if x is exact while y has some uncertainty Δy, in the
>> relation y = k * x + b?
>
>Again, no: this is not a linear model. Assumption in a linear model is
>that the errors are identically distributed.

Surely not; errors in a linear model do not need to be homoscedastic. lm handles heteroscadasticity in y via weights, and the formulation above looks  to be simply a linear model with heteroscedastic error in y.

What lm will _not_ do is fit the fixed effects model taking acount _solely_ of the 'uncertainties' in x. It will use the weighted sum of squared residuals, and although that is the usual thing to do it may not be what the OP wants. 

But since the OP first asked about fitting with error in x one might suspect there is more to it; if this is just the original question turned round, the answer would be that turning the regression round is only sensible when y was the predictor in the first place - in which case the original question was the wrong way round. And if the OP is now simply ignoring error in x that is actually present, that too would speak against simple linear regression.

Those are pretty fundamental issues, so finding a local statistician is indeed the only safe course.

S Ellison
*******************************************************************
This email and any attachments are confidential. Any use...{{dropped:8}}



More information about the R-help mailing list