public double getReliability() { int count = 0; double accuracy = 0; for (String label: labelMap.keySet()) { if (!label.equals(defaultLabel)) { accuracy += getAccuracy(label); } count++; } return accuracy / count; }
public double getReliability() { int count = 0; double accuracy = 0; for (String label: labelMap.keySet()) { if (!label.equals(defaultLabel)) { accuracy += getAccuracy(label); } count++; } return accuracy / count; }
public double getReliability() { int count = 0; double accuracy = 0; for (String label: labelMap.keySet()) { if (!label.equals(defaultLabel)) { accuracy += getAccuracy(label); } count++; } return accuracy / count; }
StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getKappa()), 10)).append('\n'); returnString.append(StringUtils.rightPad("Accuracy", 40)).append( StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getAccuracy()), 10)).append("%\n"); returnString.append(StringUtils.rightPad("Reliability", 40)).append( StringUtils.leftPad(decimalFormatter.format(normStats.getAverage() * 100.00000001), 10)).append("%\n");
private static void checkAccuracy(ConfusionMatrix cm) { Collection<String> labelstrs = cm.getLabels(); assertEquals(3, labelstrs.size()); assertEquals(25.0, cm.getAccuracy("Label1"), EPSILON); assertEquals(55.5555555, cm.getAccuracy("Label2"), EPSILON); assertTrue(Double.isNaN(cm.getAccuracy("other"))); }
StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getKappa()), 10)).append('\n'); returnString.append(StringUtils.rightPad("Accuracy", 40)).append( StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getAccuracy()), 10)).append("%\n"); returnString.append(StringUtils.rightPad("Reliability", 40)).append( StringUtils.leftPad(decimalFormatter.format(normStats.getAverage() * 100.00000001), 10)).append("%\n");
StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getKappa()), 10)).append('\n'); returnString.append(StringUtils.rightPad("Accuracy", 40)).append( StringUtils.leftPad(decimalFormatter.format(confusionMatrix.getAccuracy()), 10)).append("%\n"); returnString.append(StringUtils.rightPad("Reliability", 40)).append( StringUtils.leftPad(decimalFormatter.format(normStats.getAverage() * 100.00000001), 10)).append("%\n");