Skip to content

Commit

Permalink
Merge pull request #58 from rki-mf1/dev
Browse files Browse the repository at this point in the history
Dev: critical bugfix in sompy summary
  • Loading branch information
Krannich479 authored Jun 10, 2024
2 parents 64ac2fc + 78690de commit cd23ddc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
'0.4.0'
'0.4.1'
4 changes: 2 additions & 2 deletions aux/sompy_summary_of_summaries.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ def f1_score(recall: float, precision:float) -> float:
# | OUTPUT |
# ++++++++++++++
assert(header.rstrip().split(",")[9] == "recall")
recall_field_idx = 9
recall_field_idx = 9 - 2 # because in the line buffer we chopped 2 indices to only have numeric fields
assert(header.rstrip().split(",")[13] == "precision")
precision_field_idx = 13
precision_field_idx = 13 - 2 # because in the line buffer we chopped 2 indices to only have numeric fields
print(header4outputfile(header))
print("0,indels," + ','.join(str(x) for x in indel_lines_avg) + ',' + str(f1_score(indel_lines_avg[recall_field_idx], indel_lines_avg[precision_field_idx])) + ",-,-")
print("1,SNVs," + ','.join(str(x) for x in snv_lines_avg) + ',' + str(f1_score(snv_lines_avg[recall_field_idx], snv_lines_avg[precision_field_idx])) + ",-,-")

0 comments on commit cd23ddc

Please sign in to comment.