From 15c70890af3d83d91b123ddc284aeb3588ed1bbd Mon Sep 17 00:00:00 2001 From: Zewen Kelvin Tuong Date: Thu, 15 Feb 2024 12:12:25 +1000 Subject: [PATCH] Revert "check if incorrect dimensions and pad numbers if missing (#57)" (#61) This reverts commit 51a576c02904be06fb2bfe9f3e7283d0b5b40ef3. --- ktplotspy/plot/plot_cpdb.py | 8 -------- 1 file changed, 8 deletions(-) diff --git a/ktplotspy/plot/plot_cpdb.py b/ktplotspy/plot/plot_cpdb.py index 7a92b62..a97deb1 100644 --- a/ktplotspy/plot/plot_cpdb.py +++ b/ktplotspy/plot/plot_cpdb.py @@ -178,14 +178,6 @@ def plot_cpdb( metadata = adata.obs.copy() means_mat = prep_table(data=means) pvals_mat = prep_table(data=pvals) - missing_cols = [] - for col in means_mat.columns: - if col not in pvals_mat.columns: - missing_cols.append(col) - if len(missing_cols) > 0: - epty = np.zeros((pvals_mat.shape[0], len(missing_cols))) + 1 - missing_df = pd.DataFrame(epty, columns=missing_cols, index=pvals_mat.index) - pvals_mat = pd.concat([pvals_mat, missing_df], axis=1) if (interaction_scores is not None) & (cellsign is not None): raise KeyError("Please specify either interaction scores or cellsign, not both.")