- Timestamp:
- Dec 10, 2015, 2:48:58 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/Ohana/src/opihi/cmd.astro/fitplx_irls.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/opihi/cmd.astro/fitplx_irls.c
r39236 r39243 387 387 double ax, ay; 388 388 double bx, by; 389 double lambda ;389 double lambda_x, lambda_y; 390 390 double sigma_robust_x, sigma_robust_y; 391 391 double sigma_final_x, sigma_final_y; … … 396 396 ax = 0.0; ay = 0.0; 397 397 bx = 0.0; by = 0.0; 398 lambda = 0.0; 398 399 399 for (i = 0; i < Npts; i++) { 400 400 Wx[i] = weight_cauchy(rx[i] / dX[i]); … … 415 415 by /= 1.0 * (Npts - p); 416 416 417 sigma_robust_x = lambda * sqrt(bx) * sigma_hat * 2.385 / ax; 418 sigma_robust_y = lambda * sqrt(by) * sigma_hat * 2.385 / ay; 417 lambda_x = 1.0 + (p / Npts) * (1 - ax) / ax; 418 lambda_y = 1.0 + (p / Npts) * (1 - ay) / ay; 419 420 sigma_robust_x = lambda_x * sqrt(bx) * sigma_hat * 2.385 / ax; 421 sigma_robust_y = lambda_y * sqrt(by) * sigma_hat * 2.385 / ay; 419 422 420 423 // This is actually sigma^2, as that's the factor in the covariance (dumouchel 4.1)
Note:
See TracChangeset
for help on using the changeset viewer.
