Complete Excel output for bestResults with Friedman test

This commit is contained in:
2023-09-28 18:52:37 +02:00
parent cfcf3c16df
commit 9d3d9cc6c6
6 changed files with 139 additions and 33 deletions

View File

@@ -38,12 +38,20 @@ namespace platform {
}
lxw_format* ExcelFile::efectiveStyle(const string& style)
{
lxw_format* efectiveStyle;
if (style == "") {
efectiveStyle = NULL;
} else {
lxw_format* efectiveStyle = NULL;
if (style != "") {
string suffix = row % 2 ? "_odd" : "_even";
efectiveStyle = styles.at(style + suffix);
try {
efectiveStyle = styles.at(style + suffix);
}
catch (const out_of_range& oor) {
try {
efectiveStyle = styles.at(style);
}
catch (const out_of_range& oor) {
throw invalid_argument("Style " + style + " not found");
}
}
}
return efectiveStyle;
}