lte__ - 1 year ago 91

Python Question

What mathematical model does the Linear Regression function use in scikit learn? The Ordinary Least Squares model has more than one way to minimize the cost function. I've found the form of the function it solves here, but I'm also interested which method it uses exactly. Can anyone elaborate? Thank you!

Recommended for you: Get network issues from **WhatsUp Gold**. **Not end users.**

Answer Source

You can basically hunt around the source code enough, and you'll find it.

In

`base.py`

, you can find it uses`linal.lstsq`

.In

`linalg.py`

, you can see that`lstsq`

uses the`dglelsd`

family.This family is SVD-related. It uses SVD to solve the original problem.

Recommended from our users: **Dynamic Network Monitoring from WhatsUp Gold from IPSwitch**. ** Free Download**