3.0.2 • Published 8 months ago

ml-regression-exponential v3.0.2

Weekly downloads
3,925
License
MIT
Repository
github
Last release
8 months ago

regression-exponential

NPM version build status npm download

Exponential Regression.

Installation

$ npm i ml-regression-exponential

Usage

This calculates parameters A and B for the equation y = B * e^(A * x).

import { ExponentialRegression } from 'ml-regression-exponential';

const x = [0, 1, 2, 3, 4];
const y = [1.5, 2.5, 3.5, 5.0, 7.5];

const regression = new ExponentialRegression(x, y);

regression.A; // 0.391202
regression.B; // 1.579909
regression.predict(2); // 3.454825
regression.toString(3); // f(x) = 1.58 * exp(0.391 * x)

License

MIT

3.0.2

8 months ago

3.0.1

1 year ago

3.0.0

1 year ago

2.1.3

1 year ago

2.1.2

1 year ago

2.1.0

4 years ago

2.0.0

6 years ago

1.0.1

8 years ago

1.0.0

8 years ago