diff --git a/bin/summary_hash.py b/bin/summary_hash.py index 11d1e91..d74fa32 100755 --- a/bin/summary_hash.py +++ b/bin/summary_hash.py @@ -241,7 +241,7 @@ def htodemux_summary(htodemux_res, raw_adata, raw_mudata): if raw_mudata is not None: mudata = raw_mudata.copy() - mudata['rna'].obs = mudata['rna'].obs.merge(htodemux_assign, left_index=True, right_on='Barcode', how='left').set_index('Barcode') + mudata['rna'].obs = mudata['rna'].obs.merge(htodemux_assign, left_index=True, right_index=True, how='left') mudata['rna'].obs.rename(columns={mudata['rna'].obs.columns[0]: 'donor'}, inplace=True) mudata['rna'].obs.donor = mudata['rna'].obs.donor.fillna("negative") mudata['rna'].obs.donor = mudata['rna'].obs.donor.astype(str)