StumbleUponExecutor

The StumbleUponExecutor (https://github.com/ml-resources/spark-ml/blob/branch-ed2/Chapter_06/2.0.0/scala-spark-app/src/main/scala/org/sparksamples/classification/stumbleupon/StumbleUponExecutor.scala) object can be used to choose and run the respective classification model; for example, to run LogisiticRegression and to execute the logistic regression pipeline, set program argument as LR. For other commands, refer to the following code snippet:

case "LR" => LogisticRegressionPipeline.logisticRegressionPipeline(vectorAssembler, dataFrame) case "DT" => DecisionTreePipeline.decisionTreePipeline(vectorAssembler, dataFrame) case "RF" => RandomForestPipeline.randomForestPipeline(vectorAssembler, dataFrame) case "GBT" => GradientBoostedTreePipeline.gradientBoostedTreePipeline(vectorAssembler, ...

Get Machine Learning with Spark - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.