Skip to content

Commit d8a0ed1

Browse files
committed
Contrast set fix: group labels written in the log instead of numerical identifiers.
1 parent 8ffe07f commit d8a0ed1

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

adaa.analytics.rules/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ codeQuality {
2727
}
2828

2929
sourceCompatibility = 1.8
30-
version = '1.7.20'
30+
version = '1.7.21'
3131

3232

3333
jar {

adaa.analytics.rules/src/main/java/adaa/analytics/rules/logic/representation/ContrastSurvivalRuleSet.java

+4-1
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,16 @@ public String toString() {
6262
sb.append(super.toString());
6363
sb.append("\nEstimator:\n");
6464

65+
IContrastExampleSet ces = (IContrastExampleSet)trainingSet;
66+
List<String> groups = ces.getContrastAttribute().getMapping().getValues();
67+
6568
// get times from training estimator
6669
ArrayList<Double> times = trainingEstimator.getTimes();
6770

6871
// build header
6972
sb.append("time,entire-set");
7073
for (int i = 0; i < groupEstimators.size(); ++i) {
71-
sb.append(",group-" + (i + 1));
74+
sb.append(",group-" + groups.get(i));
7275
}
7376

7477
for (int i = 0; i < rules.size(); ++i) {

0 commit comments

Comments
 (0)