SMO confidence measure in weka

后端 未结 1 1487
孤街浪徒
孤街浪徒 2021-01-03 05:22

I\'m writing a classification code using the smo class of weka. But what i\'m yet to find is a confidence measure of the classification of an instance. It alway

相关标签:
1条回答
  • 2021-01-03 05:49

    Ok I figured out how to get this in case it might help someone. Get the source code for SMO.java and add it to your package. Resolve imports if any. Set m_fitLogisticModels to true. Change smo.buildClassifier(train, cl1, cl2, false, -1, -1); to smo.buildClassifier(train, cl1, cl2, true, -1, -1);. And viola ! distributionForInstance returns confidence scores instead of a hard 0/1.

    0 讨论(0)
提交回复
热议问题