From f5ffee7e970297347c25d972d820743d7a72b9f3 Mon Sep 17 00:00:00 2001 From: krishnakalyan3 Date: Sat, 10 Dec 2016 01:30:45 +0100 Subject: [PATCH 1/3] add quotes around options --- .../main/scala/org/apache/spark/ml/feature/Bucketizer.scala | 4 ++-- .../org/apache/spark/ml/feature/QuantileDiscretizer.scala | 4 ++-- python/pyspark/ml/feature.py | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala b/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala index eb4d42f255345..835fa49647fa3 100644 --- a/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala +++ b/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala @@ -78,8 +78,8 @@ final class Bucketizer @Since("1.4.0") (@Since("1.4.0") override val uid: String def setOutputCol(value: String): this.type = set(outputCol, value) /** - * Param for how to handle invalid entries. Options are skip (filter out rows with - * invalid values), error (throw an error), or keep (keep invalid values in a special additional + * Param for how to handle invalid entries. Options are 'skip' (filter out rows with + * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special additional * bucket). * Default: "error" * @group param diff --git a/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala b/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala index b4fcfa2da47de..60a17bfe51ab6 100644 --- a/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala +++ b/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala @@ -66,8 +66,8 @@ private[feature] trait QuantileDiscretizerBase extends Params def getRelativeError: Double = getOrDefault(relativeError) /** - * Param for how to handle invalid entries. Options are skip (filter out rows with - * invalid values), error (throw an error), or keep (keep invalid values in a special additional + * Param for how to handle invalid entries. Options are 'skip' (filter out rows with + * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special additional * bucket). * Default: "error" * @group param diff --git a/python/pyspark/ml/feature.py b/python/pyspark/ml/feature.py index 1d62b325344e5..62c31431b58ff 100755 --- a/python/pyspark/ml/feature.py +++ b/python/pyspark/ml/feature.py @@ -165,8 +165,8 @@ class Bucketizer(JavaTransformer, HasInputCol, HasOutputCol, JavaMLReadable, Jav typeConverter=TypeConverters.toListFloat) handleInvalid = Param(Params._dummy(), "handleInvalid", "how to handle invalid entries. " + - "Options are skip (filter out rows with invalid values), " + - "error (throw an error), or keep (keep invalid values in a special " + + "Options are 'skip' (filter out rows with invalid values), " + + "'error' (throw an error), or 'keep' (keep invalid values in a special " + "additional bucket).", typeConverter=TypeConverters.toString) From 72f26488d80c9582c212c442cd211534ca8d0730 Mon Sep 17 00:00:00 2001 From: krishnakalyan3 Date: Sat, 10 Dec 2016 18:24:32 +0100 Subject: [PATCH 2/3] fix style error --- .../main/scala/org/apache/spark/ml/feature/Bucketizer.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala b/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala index 835fa49647fa3..d1f3b2af1e482 100644 --- a/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala +++ b/mllib/src/main/scala/org/apache/spark/ml/feature/Bucketizer.scala @@ -79,8 +79,8 @@ final class Bucketizer @Since("1.4.0") (@Since("1.4.0") override val uid: String /** * Param for how to handle invalid entries. Options are 'skip' (filter out rows with - * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special additional - * bucket). + * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special + * additional bucket). * Default: "error" * @group param */ From c296f1e5aca8fb6abf082b9d39163c10fe819cbe Mon Sep 17 00:00:00 2001 From: krishnakalyan3 Date: Sat, 10 Dec 2016 18:36:32 +0100 Subject: [PATCH 3/3] fix style error --- .../org/apache/spark/ml/feature/QuantileDiscretizer.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala b/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala index 60a17bfe51ab6..80c7f55e26b84 100644 --- a/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala +++ b/mllib/src/main/scala/org/apache/spark/ml/feature/QuantileDiscretizer.scala @@ -67,8 +67,8 @@ private[feature] trait QuantileDiscretizerBase extends Params /** * Param for how to handle invalid entries. Options are 'skip' (filter out rows with - * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special additional - * bucket). + * invalid values), 'error' (throw an error), or 'keep' (keep invalid values in a special + * additional bucket). * Default: "error" * @group param */