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 simple linear regression example #51

Closed
opatiny opened this issue Apr 6, 2023 · 3 comments · Fixed by #58 or #59
Closed

Add simple linear regression example #51

opatiny opened this issue Apr 6, 2023 · 3 comments · Fixed by #58 or #59
Assignees

Comments

@opatiny
Copy link
Contributor

opatiny commented Apr 6, 2023

I have been trying to use the library and am struggling a bit with the results I'm obtaining. I think it would be really practical to have a very basic linear regression example to help understand how the library works.

I have also checked the testcases and haven't seen a very basic test easy to understand.

@jobo322
Copy link
Member

jobo322 commented Apr 6, 2023

Hello @opatiny, how is the function that you provide, I think it is the problem.

It should has the shape

type Parameter = number[];
const func = ([a, b]) => {
   return (x) =>  a * x + b
}

I will generate some picture to add the example but hope it would useful

@opatiny
Copy link
Contributor Author

opatiny commented Apr 6, 2023

Hi @jobo322 , thanks for your answer! I managed to get it work but I still think an example could be useful ;)

@jacobq
Copy link
Contributor

jacobq commented Apr 8, 2023

@opatiny Now that you've figured it out, would you be willing to submit a PR that improves the documentation/examples? I can help edit & review it.

@opatiny opatiny self-assigned this Apr 13, 2023
opatiny added a commit that referenced this issue Apr 13, 2023
jacobq pushed a commit that referenced this issue Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants