Send Close Add comments: (status displays here)
Got it!  This site "robinsnyder.com" uses cookies. You consent to this by clicking on "Got it!" or by continuing to use this website.  Note: This appears on each machine/browser from which this site is accessed.
Matplotlib: Linear regression
by RS  admin@robinsnyder.com : 1024 x 640


1. Linear regression
Here is an example of linear regression using numpy, sklearn and matplotlib.

2. Data
Here is the data to be used as an example.
x y 1 2 2 1 3 4 4 3 5 6 6 5 7 8

Here is the Python code [#1]

Here is the output of the Python code.


3. Regression chart
simple linear regression

4. End of page

by RS  admin@robinsnyder.com : 1024 x 640