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

[Feature Request]: Add regression line equation and R^2 #1475

Open
shun2wang opened this issue Oct 26, 2021 · 5 comments
Open

[Feature Request]: Add regression line equation and R^2 #1475

shun2wang opened this issue Oct 26, 2021 · 5 comments

Comments

@shun2wang
Copy link
Contributor

shun2wang commented Oct 26, 2021

Description

In many cases, we need to get the regression line equation or the fitted curve equation,and R^2.

Purpose

Intuitively get the equations and R^2 in the plots.

Use-case

No response

Is your feature request related to a problem?

N/A

Describe the solution you would like

No response

Describe alternatives that you have considered

See here:https://stackoverflow.com/questions/7549694/add-regression-line-equation-and-r2-on-graph

Additional context

No response

@boutinb
Copy link
Contributor

boutinb commented Oct 29, 2021

@vandenman Is it something you could add?

@vandenman
Copy link
Contributor

We could add this to say, linear regression, but it's unclear to me how to make such a plot when there are more than two variables.

@shun2wang
Copy link
Contributor Author

Thank you for considering adding this feature. and there some URL can help for nonlinear curve fitting expression and plots.
https://www.statforbiology.com/nonlinearregression/usefulequations#curve_shapes
http://sia.webpopix.org/nonlinearRegression.html

@tomtomme
Copy link
Member

tomtomme commented Jan 12, 2024

@shun2wang
The equation can also be separate from the plot.
Or is it essential, that the formula is part of the plot?
Not from my perspective since I would folllow Tuftes "minimal inc" approach.

Also the links above do not show how this would be solved for more than say four variables. You can color code the third var and do a matrix/panel plot for the fourth like flexplot does - but then the formula would need to reside above said matrix/panel of plots - which is essentially an external / separate equation again.

@tomtomme
Copy link
Member

like in Quality Control module:

Image

@tomtomme tomtomme changed the title [Feature Request]: Add regression line equation and R^2 on plot [Feature Request]: Add regression line equation and R^2 Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants