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

Return the equation of the curve. #2

Open
andrewoficial opened this issue Aug 19, 2020 · 1 comment
Open

Return the equation of the curve. #2

andrewoficial opened this issue Aug 19, 2020 · 1 comment

Comments

@andrewoficial
Copy link

Would like to be able to get the equation of the curve that was calculated.
Or the coefficients of the polynomials used to build the curve.

изображение
изображение

@henryjburg
Copy link

Have you tried logging the model you've generated? That's how I was able to get coefficients for the logistic regression at least.

I fit the model first to my training dataset and then I logged the model.

let model = logistic.fit(training_dataset);
console.log(model);

This outputted (obviously you will have values instead of '...'):

{
  theta: [ ... ], // these are your coefficients.
  threshold: 1,
  cost: ...,
  config: { alpha: 0.001, lambda: 0, iterations: 10000 }
}

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

No branches or pull requests

2 participants