Github user atalwalkar commented on a diff in the pull request:
https://github.com/apache/spark/pull/1908#discussion_r16148842
--- Diff: docs/mllib-linear-methods.md ---
@@ -33,24 +33,23 @@ the task of finding a minimizer of a convex function
`$f$` that depends on a var
Formally, we can write this as the optimization problem `$\min_{\wv
\in\R^d} \; f(\wv)$`, where
the objective function is of the form
`\begin{equation}
- f(\wv) :=
- \frac1n \sum_{i=1}^n L(\wv;\x_i,y_i) +
- \lambda\, R(\wv_i)
+ f(\wv) := \lambda\, R(\wv) +
+ \frac1n \sum_{i=1}^n L(\wv;\x_i,y_i)
\label{eq:regPrimal}
\ .
\end{equation}`
Here the vectors `$\x_i\in\R^d$` are the training data examples, for
`$1\le i\le n$`, and
`$y_i\in\R$` are their corresponding labels, which we want to predict.
We call the method *linear* if $L(\wv; \x, y)$ can be expressed as a
function of $\wv^T x$ and $y$.
-Several MLlib's classification and regression algorithms fall into this
category,
+Several of MLlib's classification and regression algorithms fall into this
category,
and are discussed here.
The objective function `$f$` has two parts:
-the loss that measures the error of the model on the training data,
-and the regularizer that measures the complexity of the model.
-The loss function `$L(\wv;.)$` must be a convex function in `$\wv$`.
+the regularizer that controls the complexity of the model,
+and the loss that measures the error of the model on the training data.
+The loss function `$L(\wv;.)$` is typically a convex function in `$\wv$`.
The fixed regularization parameter `$\lambda \ge 0$` (`regParam` in the
code) defines the trade-off
-between the two goals of small loss and small model complexity.
+between the two goals of minimizing the loss (i.e., training error) and
minimizing model complexity (i.e., to avoid overfitting).
--- End diff --
I fixed this particular example, though there are many other instances of
long lines. Perhaps I can create a separate PR that addresses this issue in
all the mllib markdown files...
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]