How to interpret this objective function

30 Views Asked by At

I'm terrible at interpreting math formulas and would like to ask for some help. I am going through the Scikit-learn library for machine learning in python and stumbled upon this formula:

Image to formula

This is the object function for Lasso linear model. https://scikit-learn.org/stable/modules/linear_model.html#lasso

I assume that the min w means that we wants to minimise the w and that the double horisontal lines are the absolute value.

Would it be possible to rewrite the function like: 1/(2n) * abs(Xw-y) + a*abs(w)

What I don't get is the double horisontal lines with the double 2.

1

There are 1 best solutions below

0
On BEST ANSWER

$||x||_\alpha$ (usually taken for $\alpha\ge 1$) is the $\alpha$-norm of the vector $x$. If $x\in\mathbb R^n, x=(x_1,x_2,\ldots,x_n)$, then:

$$||x||_\alpha=\sqrt[\alpha]{|x_1|^\alpha+|x_2|^\alpha+\ldots+|x_n|^\alpha}$$

In particular:

$$||x||_1=|x_1|+|x_2|+\ldots+|x_n|$$

("Taxicab norm" - the distance when driven through the rectangular grid of streets in Manhattan, not being allowed to go diagonally; generalised.)

$$||x||_2=\sqrt{x_1^2+x_2^2+\ldots+x_n^2}$$

(Euclidean norm). Also, if you let $\alpha\to\infty$ then you get (as a limit):

$$||x||_\infty=\max(|x_1|,|x_2|,\ldots,|x_n|)$$

For more, here is a Wikipedia article.