spark-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m...@apache.org
Subject spark git commit: [MINOR] [MLLIB] [ML] [DOC] fixed typo: label for negative result should be 0.0 (original: 1.0)
Date Thu, 10 Sep 2015 05:10:38 GMT
Repository: spark
Updated Branches:
  refs/heads/branch-1.1 119d6cf98 -> 19835ec1f


[MINOR] [MLLIB] [ML] [DOC] fixed typo: label for negative result should be 0.0 (original:
1.0)

Small typo in the example for `LabelledPoint` in the MLLib docs.

Author: Sean Paradiso <seanparadiso@gmail.com>

Closes #8680 from sparadiso/docs_mllib_smalltypo.

(cherry picked from commit 1dc7548c598c4eb4ecc7d5bb8962a735bbd2c0f7)
Signed-off-by: Xiangrui Meng <meng@databricks.com>


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/19835ec1
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/19835ec1
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/19835ec1

Branch: refs/heads/branch-1.1
Commit: 19835ec1fae13a7251f0c66fe010c228da92c456
Parents: 119d6cf
Author: Sean Paradiso <seanparadiso@gmail.com>
Authored: Wed Sep 9 22:09:33 2015 -0700
Committer: Xiangrui Meng <meng@databricks.com>
Committed: Wed Sep 9 22:10:33 2015 -0700

----------------------------------------------------------------------
 docs/mllib-data-types.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/19835ec1/docs/mllib-data-types.md
----------------------------------------------------------------------
diff --git a/docs/mllib-data-types.md b/docs/mllib-data-types.md
index 101dc2f..70b5e76 100644
--- a/docs/mllib-data-types.md
+++ b/docs/mllib-data-types.md
@@ -144,7 +144,7 @@ import org.apache.spark.mllib.regression.LabeledPoint;
 LabeledPoint pos = new LabeledPoint(1.0, Vectors.dense(1.0, 0.0, 3.0));
 
 // Create a labeled point with a negative label and a sparse feature vector.
-LabeledPoint neg = new LabeledPoint(1.0, Vectors.sparse(3, new int[] {0, 2}, new double[]
{1.0, 3.0}));
+LabeledPoint neg = new LabeledPoint(0.0, Vectors.sparse(3, new int[] {0, 2}, new double[]
{1.0, 3.0}));
 {% endhighlight %}
 </div>
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org


Mime
View raw message