cwitools.modeling.rss_func1d¶
-
cwitools.modeling.
rss_func1d
(model_params, model_func, x, y, y_var, *args)¶ Calculate the residual sum of squares for a 1D model + 1D data.
Parameters: - model_params (list) – The parameters of the model
- model_func (callable) – The model function, of form f(params, x)
- x (numpy.array) – The observed x-axis positions
- y (numpy.array) – The observed y-axis values to fit to
- y_var (numpy.array) – Variance on y input. Required positional argument, but you may simply provide a value of 1 to ignore.
Returns: The residual sum of squares
Return type: float