Skip to content

Commit

Permalink
fix detection whether dataframe can be used for hierarchical clusteri…
Browse files Browse the repository at this point in the history
…ng based column and row sorting
  • Loading branch information
johanneskoester committed Feb 23, 2024
1 parent 5d00285 commit 5af8846
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion workflow/scripts/collect-fp-fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def get_idx_sorted_by_clustering(data):

data = data.dropna(how="all")

if not data.empty and data.shape[1] > 1:
if data.shape[1] > 1 and data.shape[0] > 1:
idx_rows = get_idx_sorted_by_clustering(data)
idx_cols = get_idx_sorted_by_clustering(data.T)
data = data.iloc[idx_rows, idx_cols]
Expand Down

0 comments on commit 5af8846

Please sign in to comment.