dist[(int)classifyInstance(instance)] = 1.0;
double classification = classifyInstance(instance); if (Instance.isMissingValue(classification)) { return dist; } else { dist[(int)classification] = 1.0; }
  public double[] distributionForInstance(Instance instance) throws Exception {    double[] dist = new double[instance.numClasses()];    switch (instance.classAttribute().type()) {    case Attribute.NOMINAL:      dist[(int)classifyInstance(instance)] = 1.0;      return dist;    case Attribute.NUMERIC:      dist[0] = classifyInstance(instance);      return dist;    default:      return dist;    }  }    