You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@predictionio.apache.org by ch...@apache.org on 2017/09/27 22:11:06 UTC

[31/50] [abbrv] incubator-predictionio git commit: Fix use of case class in textclassifier example

Fix use of case class in textclassifier example

Closes #426


Project: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/commit/9c68d86c
Tree: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/tree/9c68d86c
Diff: http://git-wip-us.apache.org/repos/asf/incubator-predictionio/diff/9c68d86c

Branch: refs/heads/master
Commit: 9c68d86c61a06b08d618b8cd8177c9d76cd86618
Parents: 350b183
Author: Naoki Takezoe <ta...@apache.org>
Authored: Tue Aug 29 14:03:36 2017 +0900
Committer: Naoki Takezoe <ta...@apache.org>
Committed: Tue Aug 29 14:03:36 2017 +0900

----------------------------------------------------------------------
 docs/manual/source/demo/textclassification.html.md.erb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-predictionio/blob/9c68d86c/docs/manual/source/demo/textclassification.html.md.erb
----------------------------------------------------------------------
diff --git a/docs/manual/source/demo/textclassification.html.md.erb b/docs/manual/source/demo/textclassification.html.md.erb
index 788178d..9830d3d 100644
--- a/docs/manual/source/demo/textclassification.html.md.erb
+++ b/docs/manual/source/demo/textclassification.html.md.erb
@@ -570,7 +570,7 @@ Once you have a vector of class probabilities, you can classify the text documen
   def predict(doc : String) : PredictedResult = {
     val x: Array[Double] = getScores(doc)
     val y: (Double, Double) = (nb.labels zip x).maxBy(_._2)
-    new PredictedResult(pd.categoryMap.getOrElse(y._1, ""), y._2)
+    PredictedResult(pd.categoryMap.getOrElse(y._1, ""), y._2)
   }
 ```