In weight calculation use unweighted variance from last regression

This fixes a positive feedback where weights could reach inf.
Also change the SD_TO_DIST_RATIO constant to get close to the original
response.
This commit is contained in:
Miroslav Lichvar
2011-04-13 18:43:25 +02:00
parent 2a0c35646c
commit 165e6805ab
3 changed files with 18 additions and 9 deletions

View File

@@ -86,6 +86,7 @@ RGR_FindBestRegression
double *b0, /* estimated y axis intercept */
double *b1, /* estimated slope */
double *s2, /* estimated variance of data points */
double *us2, /* estimated unweighted variance of data points */
double *sb0, /* estimated standard deviation of
intercept */