Re: Question about SVM mlllib...

2014-10-13 Thread Sean Owen
Aside from some syntax errors, this looks like exactly how you do it, right? Except that you call clearThreshold(), which causes it to return the margin, not a 0/1 prediction. Don't call that. It will default to the behavior you want. On Mon, Oct 13, 2014 at 3:03 PM, Alfonso Muñoz Muñoz wrote: >

Question about SVM mlllib...

2014-10-13 Thread Alfonso Muñoz Muñoz
Dear friends, Is there any way to know what is the “predicted label” for each “input label”? [CODE] … Val model=SVMWithSGD.train(training,numIterations) Model.clearThreshold() Val scoreAndLabels = test.map{ point => Val score = model.predict(point.features) (predi