So I am trying to print the model output from MLlib however I am only
getting things like the following:
org.apache.spark.mllib.tree.model.DecisionTreeModel@1120c600
0.17171527904439082
0.8282847209556092
5273125.0
2.5435412E7
from the following code:
val trainErr = labelAndPreds.filter(r => r._1 !=
r._2).count.toDouble / cleanedData2.count
val trainSucc = labelAndPreds.filter(r => r._1 ==
r._2).count.toDouble / cleanedData2.count
val trainErrCount = labelAndPreds.filter(r => r._1 != r._2).count.toDouble
val trainSuccCount = labelAndPreds.filter(r => r._1 ==
r._2).count.toDouble
print(model)
println(trainErr)
println(trainSucc)
println(trainErrCount)
println(trainSuccCount)
I have also tried the following:
val model_string = model.toString()
print(model_string)
And I still do not get the model to print but where it resides in memory.
Thanks,
J
*JIMMY MCERLAIN*
DATA SCIENTIST (NERD)
*. . . . . . . . . . . . . . . . . .*
*IF WE CAN’T DOUBLE YOUR SALES,*
*ONE OF US IS IN THE WRONG BUSINESS.*
*E*: [email protected]
*M*: *510.303.7751*
ᐧ