class KiePMMLRegressionClassificationTable extends KiePMMLRegressionTable {

    @Override
    public Object evaluateRegression(Map<String, Object> input) {
        final LinkedHashMap<String, Double> resultMap = new LinkedHashMap<>();
        for (Map.Entry<String, KiePMMLRegressionTable> entry : categoryTableMap.entrySet()) {
            resultMap.put(entry.getKey(), (Double) entry.getValue().evaluateRegression(input));
        }
        final LinkedHashMap<String, Double> probabilityMap = getProbabilityMap(resultMap);
        final Map.Entry<String, Double> predictedEntry = Collections.max(probabilityMap.entrySet(), Map.Entry.comparingByValue());
        probabilityMap.put(targetField, predictedEntry.getValue());
        populateOutputFieldsMapWithResult(predictedEntry.getKey());
        populateOutputFieldsMapWithProbability(predictedEntry, probabilityMap);
        return predictedEntry.getKey();
    }

}