Skip to content
Snippets Groups Projects
Commit b77d3b96 authored by Joseph K. Bradley's avatar Joseph K. Bradley Committed by Xiangrui Meng
Browse files

[SPARK-9586] [ML] Update BinaryClassificationEvaluator to use setRawPredictionCol

Update BinaryClassificationEvaluator to use setRawPredictionCol, rather than setScoreCol. Deprecated setScoreCol.

I don't think setScoreCol was actually used anywhere (based on search).

CC: mengxr

Author: Joseph K. Bradley <joseph@databricks.com>

Closes #7921 from jkbradley/binary-eval-rawpred and squashes the following commits:

e5d7dfa [Joseph K. Bradley] Update BinaryClassificationEvaluator to use setRawPredictionCol
parent 571d5b53
No related branches found
No related tags found
No related merge requests found
...@@ -28,7 +28,7 @@ import org.apache.spark.sql.types.DoubleType ...@@ -28,7 +28,7 @@ import org.apache.spark.sql.types.DoubleType
/** /**
* :: Experimental :: * :: Experimental ::
* Evaluator for binary classification, which expects two input columns: score and label. * Evaluator for binary classification, which expects two input columns: rawPrediction and label.
*/ */
@Experimental @Experimental
class BinaryClassificationEvaluator(override val uid: String) class BinaryClassificationEvaluator(override val uid: String)
...@@ -50,6 +50,13 @@ class BinaryClassificationEvaluator(override val uid: String) ...@@ -50,6 +50,13 @@ class BinaryClassificationEvaluator(override val uid: String)
def setMetricName(value: String): this.type = set(metricName, value) def setMetricName(value: String): this.type = set(metricName, value)
/** @group setParam */ /** @group setParam */
def setRawPredictionCol(value: String): this.type = set(rawPredictionCol, value)
/**
* @group setParam
* @deprecated use [[setRawPredictionCol()]] instead
*/
@deprecated("use setRawPredictionCol instead", "1.5.0")
def setScoreCol(value: String): this.type = set(rawPredictionCol, value) def setScoreCol(value: String): this.type = set(rawPredictionCol, value)
/** @group setParam */ /** @group setParam */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment