@Override public double[] distributionForInstance(Instance inst) throws Exception {
  if (m_thresholds != null) {
    double[] dist=m_IterativeClassifier.distributionForInstance(inst);
    double[] newDist=new double[dist.length];
    for (int i=0; i < dist.length; i++) {
      if (dist[i] >= m_thresholds[i]) {
        newDist[i]=1.0;
      }
    }
    Utils.normalize(newDist);
    return newDist;
  }
 else {
    return m_IterativeClassifier.distributionForInstance(inst);
  }
}

@ Override public double [ ] distributionForInstance ( Instance inst ) throws Exception { if ( m_thresholds != null ) { double [ ] dist = m_IterativeClassifier . distributionForInstance ( inst ) ; double [ ] newDist = new double [ dist . length ] ; for ( int i = 0 ; i < dist . length ; i ++ ) { if ( dist [ i ] >= m_thresholds [ i ] ) { newDist [ i ] = 1.0 ; } } Utils . normalize ( newDist ) ; return newDist ; } else { return m_IterativeClassifier . distributionForInstance ( inst ) ; } }
returns the class distribution for an instance .
