Known observation SDs differ. How should residuals be scaled for a Gaussian weighted least-squares fit?
MathematicsLevel: IntermediateNonlinear least squares
Known observation SDs differ. How should residuals be scaled for a Gaussian weighted least-squares fit?
Hints
- Standardize residuals.
- The solver squares them afterward.
Answer
Divide each residual by its observation SD, giving squared weights 1/σ_i². Dividing by variance would apply the wrong weighting.
Source and licence: SciPy — nonlinear least squares · BSD-3-Clause · answer: Quantoros editorial