Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add r_square values to the results of the fitting. #68

Merged
merged 1 commit into from
Feb 21, 2024

Conversation

drodarie
Copy link
Collaborator

The coefficient of determination of a linear fitting can be used to assert its quality.
Coefficients of determinations of each fitting should be used for the validation of the pipeline. Especially, it is required to reproduce results of Rodarie et al. 2022.

@drodarie drodarie requested a review from mgeplf February 20, 2024 17:43
xdata=xdata,
ydata=ydata,
sigma=sigma,
absolute_sigma=True,
)

return {"coefficient": parameters[0][0], "standard_deviation": np.sqrt(parameters[1][0][0])}
ss_reg = np.sum((_optimize_func(xdata, parameters[0][0]) - np.mean(ydata)) ** 2)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

annoying we have to compute this ourselves.

@mgeplf mgeplf merged commit 6e76e8c into main Feb 21, 2024
5 checks passed
@mgeplf mgeplf deleted the feature/r_square_fitting branch February 21, 2024 10:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants