Repository: spark Updated Branches: refs/heads/master 7bf921276 -> 1dd68d382
[SPARK-17718][DOCS][MLLIB] Make loss function formulation label note clearer in MLlib docs ## What changes were proposed in this pull request? Move note about labels being +1/-1 in formulation only to be just under the table of formulations. ## How was this patch tested? Doc build Author: Sean Owen <[email protected]> Closes #15330 from srowen/SPARK-17718. Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/1dd68d38 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/1dd68d38 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/1dd68d38 Branch: refs/heads/master Commit: 1dd68d3827133d203e85294405400b04904879e0 Parents: 7bf9212 Author: Sean Owen <[email protected]> Authored: Mon Oct 3 18:09:36 2016 +0000 Committer: DB Tsai <[email protected]> Committed: Mon Oct 3 18:09:36 2016 +0000 ---------------------------------------------------------------------- docs/mllib-linear-methods.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/1dd68d38/docs/mllib-linear-methods.md ---------------------------------------------------------------------- diff --git a/docs/mllib-linear-methods.md b/docs/mllib-linear-methods.md index 6fcd3ae..816bdf1 100644 --- a/docs/mllib-linear-methods.md +++ b/docs/mllib-linear-methods.md @@ -78,6 +78,11 @@ methods `spark.mllib` supports: </tbody> </table> +Note that, in the mathematical formulation above, a binary label $y$ is denoted as either +$+1$ (positive) or $-1$ (negative), which is convenient for the formulation. +*However*, the negative label is represented by $0$ in `spark.mllib` instead of $-1$, to be consistent with +multiclass labeling. + ### Regularizers The purpose of the @@ -136,10 +141,6 @@ multiclass classification problems. For both methods, `spark.mllib` supports L1 and L2 regularized variants. The training data set is represented by an RDD of [LabeledPoint](mllib-data-types.html) in MLlib, where labels are class indices starting from zero: $0, 1, 2, \ldots$. -Note that, in the mathematical formulation in this guide, a binary label $y$ is denoted as either -$+1$ (positive) or $-1$ (negative), which is convenient for the formulation. -*However*, the negative label is represented by $0$ in `spark.mllib` instead of $-1$, to be consistent with -multiclass labeling. ### Linear Support Vector Machines (SVMs) --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
