Di Tanna Gian Luca
2005-Aug-04 09:52 UTC
[R] fit non linear model using weighted least squares
Dear all, I am new in using R. I'd like to fit a non linear model using weighted least squares. I am using the gnls function but I don't know how to perform a weighted least squares (my weights are a "simple" colum of data). Thank you in advance, Gian Luca [[alternative HTML version deleted]]
Di Tanna Gian Luca <GDiTanna <at> Regione.Emilia-Romagna.it> writes:> I'd like to fit a non linear model using weighted least squares. > I am using the gnls function but I don't know how to perform a weighted > least squares (my weights are a "simple" colum of data).In your case it probably would be easier to use nls (in stats) instead of gnls. There is an example using weighting on the help-page. Dieter Menne