Skip to content

Commit

Permalink
Residuals must be residuals, with a sign
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosertoli committed Oct 28, 2023
1 parent ec39496 commit 6c2cc07
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions indica/operators/spline_fit_easy.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@ def residuals(yknots):
bc_type=bc_type,
)
bckc = np.interp(x, xspl, spline(xspl))
residuals = np.sqrt((y - bckc) ** 2 / err**2)
return residuals
return (y - bckc) / err

yspl = xr.DataArray(
np.empty((len(xspl), len(ydata.t))),
Expand Down

0 comments on commit 6c2cc07

Please sign in to comment.